cellprofiler-library-nightly 5.0.0.dev413__tar.gz → 5.0.0.dev416__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.
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/PKG-INFO +1 -1
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/_version.py +3 -3
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/functions/object_processing.py +21 -0
- cellprofiler_library_nightly-5.0.0.dev416/cellprofiler_library/modules/_shrinktoobjectcenters.py +10 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/dilateimage.py +0 -2
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/dilateobjects.py +0 -2
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/erodeimage.py +0 -2
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/erodeobjects.py +0 -3
- cellprofiler_library_nightly-5.0.0.dev416/cellprofiler_library/opts/shrinktoobjectcenters.py +6 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library_nightly.egg-info/PKG-INFO +1 -1
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library_nightly.egg-info/SOURCES.txt +2 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/LICENSE +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/README.md +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/__init__.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/functions/__init__.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/functions/file_processing.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/functions/image_processing.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/functions/measurement.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/functions/segmentation.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/__init__.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_closing.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_colortogray.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_combineobjects.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_convertimagetoobjects.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_convertobjectstoimage.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_correctilluminationapply.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_crop.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_dilateimage.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_dilateobjects.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_enhanceedges.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_enhanceorsuppressfeatures.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_erodeimage.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_erodeobjects.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_expandorshrinkobjects.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_fillobjects.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_gaussianfilter.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_measureimageoverlap.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_measureobjectsizeshape.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_medialaxis.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_medianfilter.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_morph.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_morphologicalskeleton.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_opening.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_overlayobjects.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_overlayoutlines.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_reducenoise.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_removeholes.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_resize.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_savecroppedobjects.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_threshold.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/modules/_watershed.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/__init__.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/colortogray.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/convertimagetoobjects.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/convertobjectstoimage.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/correctilluminationapply.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/crop.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/enhanceorsuppressfeatures.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/measureimageoverlap.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/morph.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/objectsizeshapefeatures.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/overlayoutlines.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/removeholes.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/resize.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/structuring_elements.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/opts/threshold.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/py.typed +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library/types.py +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library_nightly.egg-info/dependency_links.txt +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library_nightly.egg-info/requires.txt +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/cellprofiler_library_nightly.egg-info/top_level.txt +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/environment.yml +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/pyproject.toml +0 -0
- {cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/setup.cfg +0 -0
{cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: cellprofiler-library-nightly
|
|
3
|
-
Version: 5.0.0.
|
|
3
|
+
Version: 5.0.0.dev416
|
|
4
4
|
Summary: cellprofiler-library implements CellProfiler's image processing and mathematical code, and is usable as a standalone library
|
|
5
5
|
Author: Anne Carpenter, Thouis (Ray) Jones, Lee Kamentsky, Vebjorn Ljosa, David Logan, Mark Bray, Madison Swain-Bowden, Allen Goodman, Claire McQuinn, Alice Lucas, Callum Tromans-Coia
|
|
6
6
|
Author-email: Beth Cimini <bcimini@broadinstitute.org>, David Stirling <dstirling@glencoesoftware.com>, Nodar Gogoberidze <ngogober@broadinstitute.org>
|
|
@@ -28,7 +28,7 @@ version_tuple: VERSION_TUPLE
|
|
|
28
28
|
commit_id: COMMIT_ID
|
|
29
29
|
__commit_id__: COMMIT_ID
|
|
30
30
|
|
|
31
|
-
__version__ = version = '5.0.0.
|
|
32
|
-
__version_tuple__ = version_tuple = (5, 0, 0, '
|
|
31
|
+
__version__ = version = '5.0.0.dev416'
|
|
32
|
+
__version_tuple__ = version_tuple = (5, 0, 0, 'dev416')
|
|
33
33
|
|
|
34
|
-
__commit_id__ = commit_id = '
|
|
34
|
+
__commit_id__ = commit_id = 'g16aa642b5'
|
|
@@ -676,3 +676,24 @@ def dilate_objects_with_structuring_element(
|
|
|
676
676
|
|
|
677
677
|
return y_data
|
|
678
678
|
|
|
679
|
+
|
|
680
|
+
###############################################################################
|
|
681
|
+
# ShrinkToObjectCenters
|
|
682
|
+
###############################################################################
|
|
683
|
+
|
|
684
|
+
|
|
685
|
+
def find_centroids(
|
|
686
|
+
label_image: ObjectSegmentation
|
|
687
|
+
) -> ObjectSegmentation:
|
|
688
|
+
input_props = skimage.measure.regionprops(
|
|
689
|
+
label_image, intensity_image=None, cache=True
|
|
690
|
+
)
|
|
691
|
+
|
|
692
|
+
input_centroids = [numpy.int_(obj["centroid"]) for obj in input_props]
|
|
693
|
+
|
|
694
|
+
output_segmented = numpy.zeros_like(label_image)
|
|
695
|
+
|
|
696
|
+
for ind, arr in enumerate(input_centroids):
|
|
697
|
+
output_segmented[tuple(arr)] = ind + 1
|
|
698
|
+
|
|
699
|
+
return output_segmented
|
cellprofiler_library_nightly-5.0.0.dev416/cellprofiler_library/modules/_shrinktoobjectcenters.py
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
from pydantic import validate_call, ConfigDict, Field
|
|
2
|
+
from typing import Annotated
|
|
3
|
+
from cellprofiler_library.types import ObjectSegmentation
|
|
4
|
+
from cellprofiler_library.functions.object_processing import find_centroids
|
|
5
|
+
|
|
6
|
+
@validate_call(config=ConfigDict(arbitrary_types_allowed=True))
|
|
7
|
+
def shrink_to_object_centers(
|
|
8
|
+
label_image: Annotated[ObjectSegmentation, Field(description="Input label image")]
|
|
9
|
+
) -> ObjectSegmentation:
|
|
10
|
+
return find_centroids(label_image)
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
# coding=utf-8
|
|
2
|
-
|
|
3
1
|
"""
|
|
4
2
|
Options and enums for ErodeObjects module
|
|
5
3
|
"""
|
|
@@ -12,4 +10,3 @@ Options and enums for ErodeObjects module
|
|
|
12
10
|
# Currently no custom enums needed for ErodeObjects as it uses standard
|
|
13
11
|
# StructuringElement configuration from cellprofiler_core. For structuring element shapes,
|
|
14
12
|
# see cellprofiler_library.opts.structuring_elements
|
|
15
|
-
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: cellprofiler-library-nightly
|
|
3
|
-
Version: 5.0.0.
|
|
3
|
+
Version: 5.0.0.dev416
|
|
4
4
|
Summary: cellprofiler-library implements CellProfiler's image processing and mathematical code, and is usable as a standalone library
|
|
5
5
|
Author: Anne Carpenter, Thouis (Ray) Jones, Lee Kamentsky, Vebjorn Ljosa, David Logan, Mark Bray, Madison Swain-Bowden, Allen Goodman, Claire McQuinn, Alice Lucas, Callum Tromans-Coia
|
|
6
6
|
Author-email: Beth Cimini <bcimini@broadinstitute.org>, David Stirling <dstirling@glencoesoftware.com>, Nodar Gogoberidze <ngogober@broadinstitute.org>
|
|
@@ -42,6 +42,7 @@ cellprofiler_library/modules/_reducenoise.py
|
|
|
42
42
|
cellprofiler_library/modules/_removeholes.py
|
|
43
43
|
cellprofiler_library/modules/_resize.py
|
|
44
44
|
cellprofiler_library/modules/_savecroppedobjects.py
|
|
45
|
+
cellprofiler_library/modules/_shrinktoobjectcenters.py
|
|
45
46
|
cellprofiler_library/modules/_threshold.py
|
|
46
47
|
cellprofiler_library/modules/_watershed.py
|
|
47
48
|
cellprofiler_library/opts/__init__.py
|
|
@@ -61,6 +62,7 @@ cellprofiler_library/opts/objectsizeshapefeatures.py
|
|
|
61
62
|
cellprofiler_library/opts/overlayoutlines.py
|
|
62
63
|
cellprofiler_library/opts/removeholes.py
|
|
63
64
|
cellprofiler_library/opts/resize.py
|
|
65
|
+
cellprofiler_library/opts/shrinktoobjectcenters.py
|
|
64
66
|
cellprofiler_library/opts/structuring_elements.py
|
|
65
67
|
cellprofiler_library/opts/threshold.py
|
|
66
68
|
cellprofiler_library_nightly.egg-info/PKG-INFO
|
{cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/LICENSE
RENAMED
|
File without changes
|
{cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/README.md
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{cellprofiler_library_nightly-5.0.0.dev413 → cellprofiler_library_nightly-5.0.0.dev416}/setup.cfg
RENAMED
|
File without changes
|