itsh5py.queue_handler#
Base module to handle the queue of open (in memory) files. The main important settings of how many filse are allowed (max_open_files) and the currently open files are exposed in the main API.
Functions
|
Adds a file (or better a LazyDict reference) to the queue. |
|
This will be run atexit and ensures that no references persist in memory and all hdf files are freed. |
|
Closes a LazyDict. |
|
Checks if a file is in the queue and thus oenened in memory. |
Show file paths of open files |
|
|
Removes file from the queue and from memory. |
- itsh5py.queue_handler.add_open_file(lazy_dict)[source]#
Adds a file (or better a LazyDict reference) to the queue.
- itsh5py.queue_handler.is_open(filepath)[source]#
Checks if a file is in the queue and thus oenened in memory.
- itsh5py.queue_handler.remove_from_queue(file)[source]#
Removes file from the queue and from memory. Only if file exists.
This is more complicated than it should be. The issue is that in the queue the actual LazyHdfDict are stored and comparison of those on remove can fail. So comaprison is done on file name basis and removal via index.