CARTAvis / fits2idia

C++ implementation of FITS to IDIA-HDF5 converter, optimised using OpenMP
GNU General Public License v3.0
2 stars 1 forks source link

Add smart conversion mode #57

Open CosmicElysium opened 7 months ago

CosmicElysium commented 7 months ago

Adds a smart converter option.

This is accessed with a "-r" flag plus an optional integer that indicates max memory allocation in MB (for example, -r2000 for 2 GB limit). If no number is indicated, then the fast mode is used as the assumption is that memory is not an issue for the user.

Currently, the memory allocation must be enough to hold the area of a chunk times the depth of the cube. Otherwise, the user receives an error, and the minimum memory is suggested.

The included converter tests also now include a way to test the smart converter option.

Important thing to note: this is a branch from the 3D mipmap calculation branch, so it includes the changes from PR #53

Closes #44

CosmicElysium commented 6 months ago

"memory allocation is not applied to the rotated data set calculation."

This needs to be re-looked at. Everything should fit in the specified memory allocation by the user.

EDIT: fixed