Memory fix patch
Created by: dyang37
This is (hopefully) the last merge for the memory fix. This PR contains Wenrui's PR #57 for readthedoc fix. Additionally, this PR contains the following memory allocation fix:
- In python recon() function, when init_image is provided as a scalar, the construction of the corresponding 3D array is moved from
cone3D.py
tointerface_cy.py
to avoid unnecessary mem alloc and copy of 3D memory space. - Move all axes swapping into Cython interface.
Both fixes above follows the convention/implementation of svmbir.
Testing: Tested with both demo_3D_shepp_logan.py
and demo_mace3D.py
.
Memory usage: Memory usage (measured before Cython interface invoking C code subroutine) drops from 4075MB down to 2712MB for a problem with sino shape = 144x512x512, recon shape = 799x473x473.