[SyneRBI/PETRIC-MaGeZ] replace home-grown RDP (Issue #10)

6 views
Skip to first unread message

Kris Thielemans

unread,
Nov 19, 2025, 10:25:19 AM11/19/25
to SyneRBI/PETRIC-MaGeZ, Subscribed
KrisThielemans created an issue (SyneRBI/PETRIC-MaGeZ#10)

@paskino tells me that his GPU is running out of memory in computing the diagonal of the Hessian for some reason.

you could consider using
https://github.com/SyneRBI/PETRIC2/blob/97aa45ecb1f9dbccc7d146537f6f5d4bca818420/SIRF_data_preparation/run_LBFGSBPC.py#L68-L82
if STIR version is >= 6.3.0


Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you are subscribed to this thread.Message ID: <SyneRBI/PETRIC-MaGeZ/issues/10@github.com>

Georg Schramm

unread,
Nov 19, 2025, 11:39:56 AM11/19/25
to SyneRBI/PETRIC-MaGeZ, Subscribed
gschramm left a comment (SyneRBI/PETRIC-MaGeZ#10)

Good point.
(1) once setup, how to I apply this the diagnonal of the hessian to an image?
(2) I guess this uses the GPU?
(3) Does @paskino have more diagnostic information?


Reply to this email directly, view it on GitHub, or unsubscribe.

You are receiving this because you are subscribed to this thread.Message ID: <SyneRBI/PETRIC-MaGeZ/issues/10/3553676950@github.com>

Georg Schramm

unread,
Nov 21, 2025, 11:34:37 AM11/21/25
to SyneRBI/PETRIC-MaGeZ, Subscribed
gschramm left a comment (SyneRBI/PETRIC-MaGeZ#10)

@KrisThielemans @paskino

I did a short comparison of my cupy reimplementation vs the STIR based RDP diag hessian:
https://github.com/gschramm/PETRIC2/blob/main/test_rdp_hess.py

  1. for the siemens data, my current implementation takes ca. 0.13s whereas Kris' stir implementaiton takes 0.65s.
  2. both give almost identical results, except for the 1st/last slice (where I am using heuristic padding which is prob. wrong)
  3. my implementation keeps all kapp_ij betwen neighboring voxels in memory and hence needs ca 7.8GB of GPU memory (depending on image size ...) @paskino is this causing your memory issues?
    In princple these weights can be recomputed / stored on the host, but that will slow down things (but in the end probably not important since we evaluated the diag Hessian currently only 2-4 times.


Reply to this email directly, view it on GitHub, or unsubscribe.

You are receiving this because you are subscribed to this thread.Message ID: <SyneRBI/PETRIC-MaGeZ/issues/10/3563799424@github.com>

Reply all
Reply to author
Forward
0 new messages