TomographicImaging / CIL

A versatile python framework for tomographic imaging
https://tomographicimaging.github.io/CIL/
Apache License 2.0
98 stars 45 forks source link

don't force numpy #1637

Open casperdcl opened 11 months ago

casperdcl commented 11 months ago

drop things like asserting type(df) is numpy.ndarray so that end-users can switch to e.g. cupy

epapoutsellis commented 11 months ago

See agnostic-DC and CIL-cupy but it is outdated

casperdcl commented 11 months ago

978 and #572 right :)

paskino commented 10 months ago

I did some work on this https://github.com/TomographicImaging/CIL/pull/1126

I made such that the user could specify which backend for the DataContainer they want to use. It became a bit complicated at creation/copy time as the API of cupy and numpy are not entirely the same.

paskino commented 4 months ago

I developed further and compared 4 different implementations of TV: Regularisation Toolkit FGP_TV, TotalVariation with backend C, NumPy and CuPy (new).

https://github.com/paskino/CIL/blob/cupy_array_copy/experiments/cupy_TV.py, see https://discord.com/channels/929016277266219038/936564472531795968/1210601876161175573

image