mehta-lab / recOrder

3D quantitative label-free imaging with phase and polarization
BSD 3-Clause "New" or "Revised" License
12 stars 4 forks source link

File listening options #443

Open ziw-liu opened 1 year ago

ziw-liu commented 1 year ago

For on-the-fly reconstruction that's planned for v1.0.0, we need to monitor file changes on the system, ideally in a portable (OS-agnostic) way.

Some options are:

  1. Use the IPC lock from zarr-python. This requires integration with the writer to write the lock file.
  2. Use Qt's file system watcher combined with zarr's chunk counting (zarr.Array.nchunks_initialized / zarr.Array.nchunks) to infer the change. This may not be safe from race conditions.
talonchandler commented 12 months ago

Thanks for looking into this @ziw-liu. Qt's file system watcher seems very promising to me...I'm excited to give it a shot.