MouseLand/cellpose

[BUG] Cellpose 3.0.7 does not remember that turning off auto-adjust saturation during image training

Closed this issue · 1 comments

Describe the bug
Cellpose 3.0.7 does not remember that turning off auto-adjust saturation during image training.

To Reproduce
Steps to reproduce the behavior:

  1. deactivate auto-adjust saturation
  2. perform training on image
  3. newly loaded image has autoadjusted saturation on again

also happens without training if any type of model is used to segment image

Logs:

(cellpose) C:\Users\leone>Cellpose
2024-04-18 15:25:55,577 [INFO] WRITING LOG OUTPUT TO C:\Users\leone.cellpose\run.log
2024-04-18 15:25:55,577 [INFO]
cellpose version: 3.0.7
platform: win32
python version: 3.8.19
torch version: 2.2.2+cu118
2024-04-18 15:25:55,792 [INFO] ** TORCH CUDA version installed and working. **
GUI_INFO: loading image: C:/Users/leone/Documents/SingleCell Local/WT mEOS Comparison/M1 Choosen/Training 18.4.24 Flowcell WT mEOS + WT vom 20.10.23/mEOS6-94.tif
GUI_INFO: selected model new Training flowcell+wt old, loading now
2024-04-18 15:28:03,801 [INFO] >> new Training flowcell+wt old << model set to be used
2024-04-18 15:28:03,801 [INFO] ** TORCH CUDA version installed and working. **
2024-04-18 15:28:03,801 [INFO] >>>> using GPU
2024-04-18 15:28:03,886 [INFO] >>>> model diam_mean = 30.000 (ROIs rescaled to this size during training)
2024-04-18 15:28:03,886 [INFO] >>>> model diam_labels = 21.940 (mean diameter of training ROIs)
GUI_INFO: diameter set to 21.94 (but can be changed)
2024-04-18 15:28:05,757 [INFO] >>>> loading model C:\Users\leone.cellpose\models\new Training flowcell+wt old
2024-04-18 15:28:05,776 [INFO] ** TORCH CUDA version installed and working. **
2024-04-18 15:28:05,776 [INFO] >>>> using GPU
2024-04-18 15:28:05,857 [INFO] >>>> model diam_mean = 30.000 (ROIs rescaled to this size during training)
2024-04-18 15:28:05,857 [INFO] >>>> model diam_labels = 21.940 (mean diameter of training ROIs)
{'lowhigh': None, 'percentile': [1.0, 99.0], 'normalize': True, 'norm3D': False, 'sharpen_radius': 0, 'smooth_radius': 0, 'tile_norm_blocksize': 0, 'tile_norm_smooth3D': 1, 'invert': False}
2024-04-18 15:28:07,621 [INFO] 7 cells found with model in 1.863 sec
GUI_INFO: 7 masks found
GUI_INFO: creating cellcolors and drawing masks
{'lowhigh': None, 'percentile': [1.0, 99.0], 'normalize': True, 'norm3D': False, 'sharpen_radius': 0, 'smooth_radius': 0, 'tile_norm_blocksize': 0, 'tile_norm_smooth3D': 1, 'invert': False}
[0, 255.0]
2024-04-18 15:28:16,551 [INFO] >>>> loading model C:\Users\leone.cellpose\models\new Training flowcell+wt old
2024-04-18 15:28:16,551 [INFO] ** TORCH CUDA version installed and working. **
2024-04-18 15:28:16,551 [INFO] >>>> using GPU
2024-04-18 15:28:16,651 [INFO] >>>> model diam_mean = 30.000 (ROIs rescaled to this size during training)
2024-04-18 15:28:16,651 [INFO] >>>> model diam_labels = 21.940 (mean diameter of training ROIs)
{'lowhigh': None, 'percentile': [1.0, 99.0], 'normalize': True, 'norm3D': False, 'sharpen_radius': 0, 'smooth_radius': 0, 'tile_norm_blocksize': 0, 'tile_norm_smooth3D': 1, 'invert': False}
2024-04-18 15:28:17,065 [INFO] 7 cells found with model in 0.513 sec
GUI_INFO: 7 masks found
GUI_INFO: creating cellcolors and drawing masks
{'lowhigh': None, 'percentile': [1.0, 99.0], 'normalize': True, 'norm3D': False, 'sharpen_radius': 0, 'smooth_radius': 0, 'tile_norm_blocksize': 0, 'tile_norm_smooth3D': 1, 'invert': False}
[0, 255.0]
2024-04-18 15:28:22,510 [INFO] ** TORCH CUDA version installed and working. **
2024-04-18 15:28:22,510 [INFO] >>>> using GPU
2024-04-18 15:28:22,517 [INFO] >> cyto3 << model set to be used
2024-04-18 15:28:22,595 [INFO] >>>> model diam_mean = 30.000 (ROIs rescaled to this size during training)
{'lowhigh': None, 'percentile': [1.0, 99.0], 'normalize': True, 'norm3D': False, 'sharpen_radius': 0, 'smooth_radius': 0, 'tile_norm_blocksize': 0, 'tile_norm_smooth3D': 1, 'invert': False}
2024-04-18 15:28:22,595 [INFO] channels set to [0, 0]
2024-04-18 15:28:22,611 [INFO] ~~~ FINDING MASKS ~~~
2024-04-18 15:28:23,012 [INFO] >>>> TOTAL TIME 0.42 sec
2024-04-18 15:28:23,018 [INFO] 7 cells found with model in 0.508 sec
GUI_INFO: 7 masks found
GUI_INFO: creating cellcolors and drawing masks
{'lowhigh': None, 'percentile': [1.0, 99.0], 'normalize': True, 'norm3D': False, 'sharpen_radius': 0, 'smooth_radius': 0, 'tile_norm_blocksize': 0, 'tile_norm_smooth3D': 1, 'invert': False}
[0, 255.0]

thanks for reporting this, it should be fixed now: pip install git+https://github.com/mouseland/cellpose.git