SIRF icon indicating copy to clipboard operation
SIRF copied to clipboard

"set_keep_views_in_cache(True)" for SPECTUBMatrix results in zero image on reconstruction

Open samdporter opened this issue 3 years ago • 5 comments

https://github.com/SyneRBI/SIRF/blob/9ef5044e8d939e27290f0876205f041cbdc60460/src/xSTIR/pSTIR/STIR.py#L830

Keep_all_views_in_cache = True results in zero image after reconstruction.

SPECTUBMatrix.set_up() is not exposed in SIRF. Could this be the issue?

See https://github.com/samdporter/SPECTissues/blob/main/minimal.py for demonstration.

Change "keep_views_in_cache" variable to True

samdporter avatar Oct 04 '22 14:10 samdporter

@samdporter I have tried to run your demo script, and found that it silently crashes at the line

am.set_up(templ_sino, im)

with any value of keep_views_in_cache because of the weird silent crash in STIR's inline function ProjDataInfoCylindrical::get_azimuthal_angle_sampling().

I am using recent STIR commit 3b85e01cb2c66c0ec328fe708bfba1c42fe5afc5.

evgueni-ovtchinnikov avatar Dec 21 '22 13:12 evgueni-ovtchinnikov

@samdporter @KrisThielemans on VM 3.3.0, calling ProjDataInfoCylindrical::get_azimuthal_angle_sampling() causes segfault, again no matter what value keep_views_in_cache has.

evgueni-ovtchinnikov avatar Dec 22 '22 17:12 evgueni-ovtchinnikov

All very weird, especially as I don't have that on my VM (but it isn't 3.3.0...). Can you record here what you did?

KrisThielemans avatar Dec 22 '22 17:12 KrisThielemans

@KrisThielemans I just put debug printing before and after get_azimuthal_angle_sampling() call in ProjMatrixByBinSPECTUB:: set_up and ran the same Python script as we did this morning

evgueni-ovtchinnikov avatar Dec 22 '22 17:12 evgueni-ovtchinnikov

  • reopened as this was auto-closed by GitHub but #1137 actually didn't fix the issue as far as we know.

KrisThielemans avatar May 11 '23 17:05 KrisThielemans