Skip to content

Commit c8b050a

Browse files
committed
Merge branch 'main' into ngio-projection
2 parents 3da52c8 + 9e4efc4 commit c8b050a

File tree

7 files changed

+90
-5
lines changed

7 files changed

+90
-5
lines changed

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
**Note**: Numbers like (\#123) point to closed Pull Requests on the fractal-tasks-core repository.
22

3+
34
* Tasks:
45
* Refactor projection task to use ngio
56
* Dependencies:
@@ -8,8 +9,12 @@
89
* CI:
910
* Remove Python 3.9 from the CI matrix
1011

12+
# 1.3.3
13+
14+
* Add new metadata (authors, category, modality, tags) to manifest models and to tasks (\#855).
1115

1216
# 1.3.2
17+
1318
* Tasks:
1419
* Add percentile-based rescaling to calculate registration task to make it more robust (\#848)
1520
* Dependencies:

fractal_tasks_core/__FRACTAL_MANIFEST__.json

Lines changed: 45 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,12 @@
33
"task_list": [
44
{
55
"name": "Convert Cellvoyager to OME-Zarr",
6+
"category": "Conversion",
7+
"modality": "HCS",
8+
"tags": [
9+
"Yokogawa",
10+
"Cellvoyager"
11+
],
612
"executable_non_parallel": "tasks/cellvoyager_to_ome_zarr_init.py",
713
"executable_parallel": "tasks/cellvoyager_to_ome_zarr_compute.py",
814
"meta_non_parallel": {
@@ -265,6 +271,12 @@
265271
},
266272
{
267273
"name": "Convert Cellvoyager Multiplexing to OME-Zarr",
274+
"category": "Conversion",
275+
"modality": "HCS",
276+
"tags": [
277+
"Yokogawa",
278+
"Cellvoyager"
279+
],
268280
"executable_non_parallel": "tasks/cellvoyager_to_ome_zarr_init_multiplex.py",
269281
"executable_parallel": "tasks/cellvoyager_to_ome_zarr_compute.py",
270282
"meta_non_parallel": {
@@ -551,6 +563,11 @@
551563
"output_types": {
552564
"is_3D": false
553565
},
566+
"category": "Image Processing",
567+
"modality": "HCS",
568+
"tags": [
569+
"Preprocessing"
570+
],
554571
"executable_non_parallel": "tasks/copy_ome_zarr_hcs_plate.py",
555572
"executable_parallel": "tasks/projection.py",
556573
"meta_non_parallel": {
@@ -672,6 +689,10 @@
672689
"output_types": {
673690
"illumination_corrected": true
674691
},
692+
"category": "Image Processing",
693+
"tags": [
694+
"Preprocessing"
695+
],
675696
"executable_parallel": "tasks/illumination_correction.py",
676697
"meta_parallel": {
677698
"cpus_per_task": 1,
@@ -736,6 +757,12 @@
736757
},
737758
{
738759
"name": "Cellpose Segmentation",
760+
"category": "Segmentation",
761+
"tags": [
762+
"Deep Learning",
763+
"Convolutional Neural Network",
764+
"Instance Segmentation"
765+
],
739766
"executable_parallel": "tasks/cellpose_segmentation.py",
740767
"meta_parallel": {
741768
"cpus_per_task": 4,
@@ -1030,6 +1057,11 @@
10301057
},
10311058
{
10321059
"name": "Calculate Registration (image-based)",
1060+
"category": "Registration",
1061+
"modality": "HCS",
1062+
"tags": [
1063+
"Multiplexing"
1064+
],
10331065
"executable_non_parallel": "tasks/image_based_registration_hcs_init.py",
10341066
"executable_parallel": "tasks/calculate_registration_image_based.py",
10351067
"meta_non_parallel": {
@@ -1161,6 +1193,11 @@
11611193
},
11621194
{
11631195
"name": "Find Registration Consensus",
1196+
"category": "Registration",
1197+
"modality": "HCS",
1198+
"tags": [
1199+
"Multiplexing"
1200+
],
11641201
"executable_non_parallel": "tasks/init_group_by_well_for_multiplexing.py",
11651202
"executable_parallel": "tasks/find_registration_consensus.py",
11661203
"meta_non_parallel": {
@@ -1263,6 +1300,11 @@
12631300
"output_types": {
12641301
"registered": true
12651302
},
1303+
"category": "Registration",
1304+
"modality": "HCS",
1305+
"tags": [
1306+
"Multiplexing"
1307+
],
12661308
"executable_parallel": "tasks/apply_registration_to_image.py",
12671309
"meta_parallel": {
12681310
"cpus_per_task": 1,
@@ -1378,6 +1420,7 @@
13781420
},
13791421
{
13801422
"name": "Napari Workflows Wrapper",
1423+
"category": "Measurement",
13811424
"executable_parallel": "tasks/napari_workflows_wrapper.py",
13821425
"meta_parallel": {
13831426
"cpus_per_task": 8,
@@ -1539,5 +1582,6 @@
15391582
}
15401583
],
15411584
"has_args_schemas": true,
1542-
"args_schema_version": "pydantic_v2"
1585+
"args_schema_version": "pydantic_v2",
1586+
"authors": "Fractal Core Team"
15431587
}

fractal_tasks_core/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,6 @@
66
)
77

88

9-
__VERSION__ = "1.3.2"
9+
__VERSION__ = "1.3.3"
1010
__OME_NGFF_VERSION__ = "0.4"
1111
__FRACTAL_TABLE_VERSION__ = "1"

fractal_tasks_core/dev/create_manifest.py

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@
3232

3333
def create_manifest(
3434
package: str = "fractal_tasks_core",
35+
authors: Optional[str] = None,
3536
manifest_version: str = "2",
3637
has_args_schemas: bool = True,
3738
docs_link: Optional[str] = None,
@@ -76,6 +77,8 @@ def create_manifest(
7677
)
7778
if has_args_schemas:
7879
manifest["args_schema_version"] = ARGS_SCHEMA_VERSION
80+
if authors is not None:
81+
manifest["authors"] = authors
7982

8083
# Prepare a default value of docs_link
8184
if package == "fractal_tasks_core" and docs_link is None:
@@ -148,4 +151,6 @@ def create_manifest(
148151

149152

150153
if __name__ == "__main__":
151-
create_manifest()
154+
PACKAGE = "fractal_tasks_core"
155+
AUTHORS = "Fractal Core Team"
156+
create_manifest(package=PACKAGE, authors=AUTHORS)

fractal_tasks_core/dev/task_list.py

Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,13 +22,19 @@
2222
executable="tasks/cellvoyager_to_ome_zarr_compute.py",
2323
meta_init={"cpus_per_task": 1, "mem": 4000},
2424
meta={"cpus_per_task": 1, "mem": 4000},
25+
category="Conversion",
26+
modality="HCS",
27+
tags=["Yokogawa", "Cellvoyager"],
2528
),
2629
CompoundTask(
2730
name="Convert Cellvoyager Multiplexing to OME-Zarr",
2831
executable_init="tasks/cellvoyager_to_ome_zarr_init_multiplex.py",
2932
executable="tasks/cellvoyager_to_ome_zarr_compute.py",
3033
meta_init={"cpus_per_task": 1, "mem": 4000},
3134
meta={"cpus_per_task": 1, "mem": 4000},
35+
category="Conversion",
36+
modality="HCS",
37+
tags=["Yokogawa", "Cellvoyager"],
3238
),
3339
CompoundTask(
3440
name="Project Image (HCS Plate)",
@@ -38,39 +44,59 @@
3844
output_types={"is_3D": False},
3945
meta_init={"cpus_per_task": 1, "mem": 4000},
4046
meta={"cpus_per_task": 1, "mem": 4000},
47+
category="Image Processing",
48+
modality="HCS",
49+
tags=["Preprocessing"],
4150
),
4251
ParallelTask(
4352
name="Illumination Correction",
4453
input_types=dict(illumination_corrected=False),
4554
executable="tasks/illumination_correction.py",
4655
output_types=dict(illumination_corrected=True),
4756
meta={"cpus_per_task": 1, "mem": 4000},
57+
category="Image Processing",
58+
tags=["Preprocessing"],
4859
),
4960
ParallelTask(
5061
name="Cellpose Segmentation",
5162
executable="tasks/cellpose_segmentation.py",
5263
meta={"cpus_per_task": 4, "mem": 16000, "needs_gpu": True},
64+
category="Segmentation",
65+
tags=[
66+
"Deep Learning",
67+
"Convolutional Neural Network",
68+
"Instance Segmentation",
69+
],
5370
),
5471
CompoundTask(
5572
name="Calculate Registration (image-based)",
5673
executable_init="tasks/image_based_registration_hcs_init.py",
5774
executable="tasks/calculate_registration_image_based.py",
5875
meta_init={"cpus_per_task": 1, "mem": 1000},
5976
meta={"cpus_per_task": 1, "mem": 8000},
77+
category="Registration",
78+
modality="HCS",
79+
tags=["Multiplexing"],
6080
),
6181
CompoundTask(
6282
name="Find Registration Consensus",
6383
executable_init="tasks/init_group_by_well_for_multiplexing.py",
6484
executable="tasks/find_registration_consensus.py",
6585
meta_init={"cpus_per_task": 1, "mem": 1000},
6686
meta={"cpus_per_task": 1, "mem": 1000},
87+
category="Registration",
88+
modality="HCS",
89+
tags=["Multiplexing"],
6790
),
6891
ParallelTask(
6992
name="Apply Registration to Image",
7093
input_types=dict(registered=False),
7194
executable="tasks/apply_registration_to_image.py",
7295
output_types=dict(registered=True),
7396
meta={"cpus_per_task": 1, "mem": 4000},
97+
category="Registration",
98+
modality="HCS",
99+
tags=["Multiplexing"],
74100
),
75101
NonParallelTask(
76102
name="Import OME-Zarr",
@@ -83,5 +109,6 @@
83109
"cpus_per_task": 8,
84110
"mem": 32000,
85111
},
112+
category="Measurement",
86113
),
87114
]

fractal_tasks_core/dev/task_models.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@
1919
from typing import Optional
2020

2121
from pydantic import BaseModel
22+
from pydantic import Field
2223

2324

2425
class _BaseTask(BaseModel):
@@ -31,6 +32,9 @@ class Config:
3132
meta: Optional[dict[str, Any]] = None
3233
input_types: Optional[dict[str, bool]] = None
3334
output_types: Optional[dict[str, bool]] = None
35+
category: Optional[str] = None
36+
modality: Optional[str] = None
37+
tags: list[str] = Field(default_factory=list)
3438

3539

3640
class CompoundTask(_BaseTask):

pyproject.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "fractal-tasks-core"
3-
version = "1.3.2"
3+
version = "1.3.3"
44
description = "Core bioimage-analysis library and tasks of the Fractal analytics platform"
55
authors = [
66
"Joel Lüthi <[email protected]>",
@@ -104,7 +104,7 @@ source = ["fractal_tasks_core"]
104104
omit = ["tests/*", "examples/*", "fractal_tasks_core/dev/*"]
105105

106106
[tool.bumpver]
107-
current_version = "1.3.2"
107+
current_version = "1.3.3"
108108
version_pattern = "MAJOR.MINOR.PATCH[PYTAGNUM]"
109109
commit_message = "bump version {old_version} -> {new_version}"
110110
commit = true

0 commit comments

Comments
 (0)