small-fish-gui 1.10.0__tar.gz → 1.10.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/PKG-INFO +2 -2
  2. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/pyproject.toml +2 -2
  3. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/__init__.py +1 -1
  4. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/gui/_napari_widgets.py +1 -1
  5. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/gui/napari_visualiser.py +10 -6
  6. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/detection.py +10 -9
  7. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/LICENSE +0 -0
  8. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/README.md +0 -0
  9. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/.github/workflows/python-publish.yml +0 -0
  10. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/LICENSE +0 -0
  11. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/README.md +0 -0
  12. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/__main__.py +0 -0
  13. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/batch/__init__.py +0 -0
  14. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/batch/input.py +0 -0
  15. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/batch/integrity.py +0 -0
  16. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/batch/pipeline.py +0 -0
  17. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/batch/prompt.py +0 -0
  18. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/batch/test.py +0 -0
  19. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/batch/update.py +0 -0
  20. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/batch/utils.py +0 -0
  21. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/batch/values.txt +0 -0
  22. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/gui/__init__.py +0 -0
  23. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/gui/animation.py +0 -0
  24. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/gui/layout.py +0 -0
  25. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/gui/prompts.py +0 -0
  26. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/gui/screenshot/general_help_screenshot.png +0 -0
  27. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/gui/screenshot/mapping_help_screenshot.png +0 -0
  28. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/gui/screenshot/segmentation_help_screenshot.png +0 -0
  29. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/gui/testing.ipynb +0 -0
  30. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/gui/theme.py +0 -0
  31. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/hints.py +0 -0
  32. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/interface/__init__.py +0 -0
  33. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/interface/image.py +0 -0
  34. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/interface/inoutput.py +0 -0
  35. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/interface/testing.py +0 -0
  36. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/__init__.py +0 -0
  37. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/_colocalisation.py +0 -0
  38. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/_custom_errors.py +0 -0
  39. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/_preprocess.py +0 -0
  40. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/_signaltonoise.py +0 -0
  41. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/actions.py +0 -0
  42. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/main.py +0 -0
  43. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/segmentation.py +0 -0
  44. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/spots.py +0 -0
  45. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/test.py +0 -0
  46. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/testing.ipynb +0 -0
  47. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/pipeline/utils.py +0 -0
  48. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/requirements.txt +0 -0
  49. {small_fish_gui-1.10.0 → small_fish_gui-1.10.2}/src/small_fish_gui/utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: small_fish_gui
3
- Version: 1.10.0
3
+ Version: 1.10.2
4
4
  Summary: Small Fish is a python application for the analysis of smFish images. It provides a ready to use graphical interface to combine famous python packages for cell analysis without any need for coding.
5
5
  Project-URL: Homepage, https://github.com/2Echoes/small_fish
6
6
  Project-URL: Wiki, https://github.com/2Echoes/small_fish_gui/wiki
@@ -10,7 +10,7 @@ License-File: LICENSE
10
10
  Classifier: License :: OSI Approved :: BSD License
11
11
  Classifier: Operating System :: OS Independent
12
12
  Classifier: Programming Language :: Python :: 3
13
- Requires-Python: >=3.8
13
+ Requires-Python: >=3.9
14
14
  Requires-Dist: aicsimageio>=4.14.0
15
15
  Requires-Dist: big-fish==0.6.2
16
16
  Requires-Dist: cellpose==3.0.7
@@ -4,13 +4,13 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "small_fish_gui"
7
- version = "1.10.0"
7
+ version = "1.10.2"
8
8
  authors = [
9
9
  { name="Slimani Floric", email="floric.slimani@live.com" },
10
10
  ]
11
11
  description = "Small Fish is a python application for the analysis of smFish images. It provides a ready to use graphical interface to combine famous python packages for cell analysis without any need for coding."
12
12
  readme = "README.md"
13
- requires-python = ">=3.8"
13
+ requires-python = ">=3.9"
14
14
  classifiers = [
15
15
  "Programming Language :: Python :: 3",
16
16
  "License :: OSI Approved :: BSD License",
@@ -37,7 +37,7 @@ ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
37
37
  (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
38
38
  SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
39
39
  """
40
- __version__ = "1.10.0"
40
+ __version__ = "1.10.2"
41
41
  __wiki__ = "https://github.com/2Echoes/small_fish_gui/wiki"
42
42
 
43
43
  import os
@@ -133,7 +133,7 @@ class SegmentationReseter(NapariWidget) :
133
133
  def __init__(self, label_list: 'list[Labels]'):
134
134
  self.label_list = label_list
135
135
  if len(self.label_list) == 0 : raise ValueError("Empty label list")
136
- self.save = self._get_save()
136
+ self.save = self._get_save(label_list)
137
137
  super().__init__()
138
138
 
139
139
 
@@ -55,6 +55,8 @@ def correct_spots(
55
55
  for im, color in zip(other_images, other_colors) :
56
56
  Viewer.add_image(im, scale=scale, blending='additive', visible=False, colormap=color, contrast_limits=[im.min(), im.max()])
57
57
 
58
+
59
+
58
60
  single_layer = Viewer.add_points( # single molecule spots; this layer can be update by user.
59
61
  spots,
60
62
  size = 5,
@@ -65,7 +67,7 @@ def correct_spots(
65
67
  symbol= 'disc',
66
68
  name= 'single spots',
67
69
  features={
68
- "cluster_id" : spot_cluster_id if not spot_cluster_id is None else [],
70
+ "cluster_id" : spot_cluster_id if not spot_cluster_id is None else [None] * len(spots),
69
71
  "end" : [True] * len(spots)
70
72
  }
71
73
  )
@@ -127,10 +129,6 @@ def correct_spots(
127
129
  Viewer.show(block=False)
128
130
  napari.run()
129
131
 
130
- new_spots = np.concatenate([
131
- single_layer.data,
132
- single_layer.features.loc[:,["cluster_id"]].to_numpy()
133
- ], axis=1).astype(int)
134
132
 
135
133
  if type(clusters) != type(None) :
136
134
  new_clusters = np.concatenate([
@@ -138,10 +136,16 @@ def correct_spots(
138
136
  cluster_layer.features.loc[:,["spot_number","cluster_id"]].to_numpy()
139
137
  ],axis=1)
140
138
 
139
+ new_spots = np.concatenate([
140
+ single_layer.data,
141
+ single_layer.features.loc[:,["cluster_id"]].to_numpy()
142
+ ], axis=1).astype(int)
143
+
141
144
  new_cluster_radius = widget_cluster_updater.cluster_radius
142
145
  new_min_spot_number = widget_cluster_updater.min_spot
143
146
 
144
- else :
147
+ else :
148
+ new_spots = single_layer.data
145
149
  new_clusters = None
146
150
  new_cluster_radius = None
147
151
  new_min_spot_number = None
@@ -217,16 +217,16 @@ def initiate_detection(user_parameters : pipeline_parameters, map_, shape) :
217
217
  if voxel_size is None or not user_parameters.get('voxel_size') is None:
218
218
  pass
219
219
  else :
220
- detection_parameters['voxel_size'] = [int(v) for v in voxel_size]
221
- detection_parameters['voxel_size_z'] = round(voxel_size[0])
222
- detection_parameters['voxel_size_y'] = round(voxel_size[1])
223
- detection_parameters['voxel_size_x'] = round(voxel_size[2])
220
+ detection_parameters['voxel_size'] = [round(v) if isinstance(v, (float,int)) else None for v in voxel_size]
221
+ detection_parameters['voxel_size_z'] = detection_parameters['voxel_size'][0]
222
+ detection_parameters['voxel_size_y'] = detection_parameters['voxel_size'][1]
223
+ detection_parameters['voxel_size_x'] = detection_parameters['voxel_size'][2]
224
224
 
225
225
  #Setting default spot size to 1.5 voxel
226
226
  if detection_parameters.get('spot_size') is None :
227
- detection_parameters['spot_size_z'] = round(detection_parameters['voxel_size_z']*1.5) if not detection_parameters['voxel_size_z'] is None else None
228
- detection_parameters['spot_size_y'] = round(detection_parameters['voxel_size_y']*1.5) if not detection_parameters['voxel_size_y'] is None else None
229
- detection_parameters['spot_size_x'] = round(detection_parameters['voxel_size_x']*1.5) if not detection_parameters['voxel_size_x'] is None else None
227
+ detection_parameters['spot_size_z'] = round(detection_parameters['voxel_size_z']*1.5) if isinstance(detection_parameters['voxel_size_z'], (float,int)) else None
228
+ detection_parameters['spot_size_y'] = round(detection_parameters['voxel_size_y']*1.5) if isinstance(detection_parameters['voxel_size_y'],(float,int)) else None
229
+ detection_parameters['spot_size_x'] = round(detection_parameters['voxel_size_x']*1.5) if isinstance(detection_parameters['voxel_size_x'],(float,int)) else None
230
230
 
231
231
  while True :
232
232
  detection_parameters = detection_parameters_promt(
@@ -275,7 +275,8 @@ def _launch_detection(image, image_input_values: dict) :
275
275
 
276
276
  if type(threshold) == type(None) :
277
277
  threshold = threshold_penalty * compute_auto_threshold(image, voxel_size=voxel_size, spot_radius=spot_size, log_kernel_size=log_kernel_size, minimum_distance=minimum_distance)
278
-
278
+ threshold = max(threshold,15) # Force threshold to be at least 15 to match napari widget and to not have too many spots for weak configs
279
+
279
280
  filtered_image = _apply_log_filter(
280
281
  image=image,
281
282
  voxel_size=voxel_size,
@@ -827,7 +828,7 @@ def _create_threshold_slider(
827
828
  'size': 5,
828
829
  'scale' : scale,
829
830
  'face_color' : 'transparent',
830
- 'edge_color' : 'red',
831
+ 'border_color' : 'red',
831
832
  'symbol' : 'disc',
832
833
  'opacity' : 0.7,
833
834
  'blending' : 'translucent',
File without changes