Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
81 commits
Select commit Hold shift + click to select a range
8aacd90
add STIRImageData::address, params.size_t_par, ImageData.address
evgueni-ovtchinnikov Apr 9, 2025
3dc4d76
`{Image,Acquisition}Data.{__array_interface__,asarray()}`
casperdcl Apr 14, 2025
f418d96
debugging & testing
evgueni-ovtchinnikov May 2, 2025
44f9551
`ImageData.asarray(copy=None)` numpy-like behaviour
casperdcl May 8, 2025
abe7601
address review comments
casperdcl Jun 24, 2025
fbf83cc
pulled array-ptr, resolved conflicts
evgueni-ovtchinnikov Jun 24, 2025
030d2ae
[ci skip] removed unused storage scheme settings from asarray.py demo
evgueni-ovtchinnikov Jun 25, 2025
43612a3
added Python CI tests for asarray method
evgueni-ovtchinnikov Jun 25, 2025
d2fb53f
fixed CI tests for asarray (test_img_asarray->asarray4img)
evgueni-ovtchinnikov Jun 25, 2025
61a7089
got rid of docopt to fix CI tests for asarray
evgueni-ovtchinnikov Jun 25, 2025
676b2e8
fix test args
casperdcl Jun 25, 2025
30d39f4
debugging
casperdcl Jun 25, 2025
4662710
debugging
casperdcl Jun 25, 2025
9eb6c55
merged origin/array-ptr (fixed CI tests except demos)
evgueni-ovtchinnikov Jun 25, 2025
ac459af
Merge branch 'array-ptr' of https://github.com/SyneRBI/SIRF into arra…
evgueni-ovtchinnikov Jun 25, 2025
6ac6ad4
trying to fix PET_DEMOS_PYTHON
evgueni-ovtchinnikov Jun 26, 2025
b1ed678
started working on array interface for ISMRMRD_Acquisition
evgueni-ovtchinnikov Jul 3, 2025
34fe063
corrected the __array_interface__ data type code (f4 -> c8)
evgueni-ovtchinnikov Jul 3, 2025
c798ec6
implemented and tested sirf.Gadgetron.Acquisition.asarray() method
evgueni-ovtchinnikov Jul 4, 2025
3353834
started working on array interface for sirf.Gadgetron.AcquisitionData
evgueni-ovtchinnikov Jul 5, 2025
ee5ae5b
implemented sirf.Gadgetron.AcquisitionDataView
evgueni-ovtchinnikov Jul 7, 2025
27ef332
implemented sirf.Gadgetron.AcquisitionDataView algebra
evgueni-ovtchinnikov Jul 8, 2025
b4bbdbd
started working on sirf.Gadgetron.ImageDataView algebra
evgueni-ovtchinnikov Jul 8, 2025
e24ce92
implemented sirf.Gadgetron.ImageDataView
evgueni-ovtchinnikov Jul 9, 2025
1c9fc08
added images algebra performance comparison tests
evgueni-ovtchinnikov Jul 9, 2025
0ad7a2e
merged array-ptr-reg onto array-ptr-mr and resolved conflicts
evgueni-ovtchinnikov Jul 10, 2025
ae6685d
added performance tests for nifti images algebra
evgueni-ovtchinnikov Jul 10, 2025
38739fc
added acquisitions algebra performance comparison tests
evgueni-ovtchinnikov Jul 10, 2025
afa5db3
added methods __isub__, norm and dot to ImageDataView
evgueni-ovtchinnikov Jul 14, 2025
73e5f8d
introduced GadgetronDataView base class to avoid algebra methods dupl…
evgueni-ovtchinnikov Jul 15, 2025
4861947
added method ImageDataView.sum and images tests for norm, sum and dot
evgueni-ovtchinnikov Jul 16, 2025
e3e6928
corrected computing ImageData views norm and dot
evgueni-ovtchinnikov Jul 22, 2025
74401c9
moved norm(x) and dot(x, y) implementation to SIRF.py
evgueni-ovtchinnikov Jul 24, 2025
cd22449
removed unused DataContainer import from Reg.py
evgueni-ovtchinnikov Jul 24, 2025
a999bed
Merge branch 'master' into array-ptr-mr
evgueni-ovtchinnikov Jul 25, 2025
be42062
commented out verbose warning in set_up_geom_info() [ci skip]
evgueni-ovtchinnikov Jul 25, 2025
ea94c83
replaced copy_view with numpy-style copyto
evgueni-ovtchinnikov Jul 25, 2025
b9b4996
tidied up/updated timings demos
evgueni-ovtchinnikov Jul 25, 2025
e1b864c
employed isinstance in the definition of SIRF's norm, dot and copyto
evgueni-ovtchinnikov Jul 25, 2025
5ec68c9
added docstrings for norm, dot and copyto, updated CHANGES.md
evgueni-ovtchinnikov Jul 25, 2025
4f46387
attended to Codacy issues
evgueni-ovtchinnikov Jul 25, 2025
df26d1b
made some corrections suggested by a reviewer
evgueni-ovtchinnikov Jul 25, 2025
66b6610
misc tidy
casperdcl Jul 25, 2025
952389c
adopted reviewer's implementation of GadgetronDataView algebra
evgueni-ovtchinnikov Jul 25, 2025
d8406e3
pulled, merged and resolved conflicts
evgueni-ovtchinnikov Jul 25, 2025
858d7da
added STIR data view testing scripts
evgueni-ovtchinnikov Jul 29, 2025
8427e50
added Gadgetron data view testing scripts
evgueni-ovtchinnikov Jul 29, 2025
7db397e
corrected ContiguousError message in SIRF.asarray
evgueni-ovtchinnikov Jul 29, 2025
cf82db8
removed star imports in view tests
evgueni-ovtchinnikov Jul 29, 2025
45e0dac
small amendments applied
evgueni-ovtchinnikov Jul 29, 2025
e46cbaf
added Registration data view test
evgueni-ovtchinnikov Jul 29, 2025
a1a8d88
added missing self.handle = None [ci skip]
evgueni-ovtchinnikov Jul 30, 2025
fde6653
Merge branch 'master' into array-ptr-mr
evgueni-ovtchinnikov Aug 29, 2025
2b1b00c
adopted some reviewer's suggestions
evgueni-ovtchinnikov Aug 29, 2025
70fb224
Merge branch 'array-ptr-mr' of https://github.com/SyneRBI/SIRF into a…
evgueni-ovtchinnikov Aug 29, 2025
ad312e5
added GadgetronDataView objects demo
evgueni-ovtchinnikov Oct 9, 2025
9126d2c
resolved conflicts
evgueni-ovtchinnikov Oct 9, 2025
ae475dc
added gadgetron data views failure example
evgueni-ovtchinnikov Oct 9, 2025
d77f39c
fixed gadgetron data views
evgueni-ovtchinnikov Oct 10, 2025
236fa0b
attended to Codacy issues
evgueni-ovtchinnikov Oct 13, 2025
e602a5c
attended to further Codacy issues
evgueni-ovtchinnikov Oct 13, 2025
d3216b3
added MR data algebra timing script
evgueni-ovtchinnikov Oct 14, 2025
e4d7117
added demo description and missing --non-interactive option in mr_tim…
evgueni-ovtchinnikov Oct 14, 2025
8a6eb90
attended to Codacy issues
evgueni-ovtchinnikov Oct 14, 2025
7a5688a
attended to Codacy issues
evgueni-ovtchinnikov Oct 15, 2025
b681cef
removed some commented-out lines [ci skip]
evgueni-ovtchinnikov Oct 15, 2025
3f95c33
updated CHANGES.md [ci skip]
evgueni-ovtchinnikov Oct 15, 2025
bc2f772
updated NOTICE.txt [ci skip]
evgueni-ovtchinnikov Oct 15, 2025
8297728
corrected NOTICE.txt [ci skip]
evgueni-ovtchinnikov Oct 17, 2025
739c2eb
trying to cover the case of old NumPy
evgueni-ovtchinnikov Oct 20, 2025
83cc562
corrected Gadgetron.Image definition (missing inheritance from ArrayC…
evgueni-ovtchinnikov Oct 20, 2025
93a02e5
attended to Codacy issues
evgueni-ovtchinnikov Oct 20, 2025
65b598b
tidy old numpy<2 handling
casperdcl Oct 20, 2025
b68b349
small amendments related to old NumPy issue
evgueni-ovtchinnikov Oct 23, 2025
d95c7bb
updated files for release 3.9.0 [ci skip]
evgueni-ovtchinnikov Oct 28, 2025
54505e7
Merge branch 'master' of https://github.com/SyneRBI/SIRF
evgueni-ovtchinnikov Oct 30, 2025
dedf83c
Merged branch 'master' of https://github.com/SyneRBI/SIRF
evgueni-ovtchinnikov Nov 8, 2025
35647f6
fixed #1363
evgueni-ovtchinnikov Jan 9, 2026
69019da
resolved conflicts
evgueni-ovtchinnikov Jan 12, 2026
a641f12
[ci skip] updated CHANGES.md
evgueni-ovtchinnikov Jan 12, 2026
7331a09
[ci skip] removed unused 'import logging' in SIRF.py
evgueni-ovtchinnikov Jan 12, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,11 @@
- `ImageData` and `AcquisitionDataInMemory` have `supports_array_view==True`

* SIRF/Gadgetron
- `ImageDataView` and `AcquisitionDataView` classes implemented that encapsulate arrays of NumPy views of `ISMRMRD_ImageData` and `ISMRMRD_AcquisitionData` objects respectively, significantly accelerating the algebraic operations (up to a factor of about 10 for images).
- `ImageDataView` and `AcquisitionDataView` classes implemented that encapsulate arrays of NumPy views of `ISMRMRD_ImageData` and `ISMRMRD_AcquisitionData` objects respectively, significantly accelerating the algebraic operations (up to a factor of about 10 for images). As these classes require numpy version major being not less than 2, tests that use them are skipped if this requirement is not met.

* SIRF/Registration
- Nifty images have `supports_array_view==True`
- PET/Registration `ImageData` and PET `AcquisitionData` have `.asarray(copy=False)` (NumPy-like behaviour: default zero-copy if contiguous, fallback to deepcopy otherwise) via `__array_interface__`.

* CI and testing
- made tests return value handling compatible with a future version of pytest.
Expand Down
7 changes: 7 additions & 0 deletions examples/Python/MR/data_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,13 @@

{licence}
"""

import numpy
numpy_major = int(numpy.__version__[0])
if numpy_major < 2:
print('Using data views requires numpy version major not less than 2, exiting.')
exit()

from sirf.SIRF import norm, dot, copyto
from sirf.Gadgetron import AcquisitionData, \
AcquisitionDataView, ImageDataView, FullySampledReconstructor
Expand Down
5 changes: 5 additions & 0 deletions examples/Python/MR/mr_timings.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,11 @@
"""

import numpy
numpy_major = int(numpy.__version__[0])
if numpy_major < 2:
print('Using data views requires numpy version major not less than 2, exiting.')
exit()

import timeit
import importlib

Expand Down