dsa-helpers 1.1.5.dev0__tar.gz → 1.1.5.dev2__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.
- {dsa_helpers-1.1.5.dev0/dsa_helpers.egg-info → dsa_helpers-1.1.5.dev2}/PKG-INFO +1 -1
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/__init__.py +1 -1
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/datasets/utils.py +4 -2
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/segformer_semantic_segmentation/train.py +8 -6
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2/dsa_helpers.egg-info}/PKG-INFO +1 -1
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/pyproject.toml +1 -1
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/.gitignore +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/.readthedocs.yaml +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/LICENSE +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/README.md +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/app.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dev.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/docs/requirements.txt +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/docs/source/conf.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/docs/source/index.rst +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/cli_utils.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/dash/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/dash/dash_paperdragon_utils.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/dash/header.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/dash/header_callbacks.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/girder_utils.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/gpd_utils.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/image_utils.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/imread.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/imwrite.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/callbacks.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/datasets/SegFormerSegmentationDataset.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/datasets/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/evaluate.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/metrics.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/object_detection/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/object_detection/get_pearce_roi_images.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/object_detection/tile_image.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/object_detection/utils.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/segformer_semantic_segmentation/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/segformer_semantic_segmentation/inference.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/transforms/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/transforms/segformer_transforms.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/mongo_utils.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/tile_utils.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/tiling.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/utils.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers.egg-info/SOURCES.txt +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers.egg-info/dependency_links.txt +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers.egg-info/requires.txt +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers.egg-info/top_level.txt +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/setup.cfg +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/tests/app/Dockerfile +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/tests/app/app.py +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/tests/docker-compose.yaml +0 -0
- {dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/tests/test.ipynb +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: dsa_helpers
|
|
3
|
-
Version: 1.1.5.
|
|
3
|
+
Version: 1.1.5.dev2
|
|
4
4
|
Summary: Utility functions for working with the DSA girder client.
|
|
5
5
|
Author-email: "Juan C. Vizcarra" <jvizcar@emory.edu>
|
|
6
6
|
Maintainer-email: "Juan C. Vizcarra" <jvizcar@emory.edu>
|
|
@@ -29,11 +29,13 @@ def create_segformer_segmentation_dataset(
|
|
|
29
29
|
if isinstance(df, str):
|
|
30
30
|
df = pd.read_csv(df, low_memory=low_memory)
|
|
31
31
|
|
|
32
|
-
dataset = SegFormerSegmentationDataset(df)
|
|
32
|
+
dataset = SegFormerSegmentationDataset(df.copy())
|
|
33
33
|
|
|
34
34
|
dataset = Dataset.from_generator(
|
|
35
35
|
generator=lambda: dataset_generator(dataset),
|
|
36
|
-
features=Features(
|
|
36
|
+
features=Features(
|
|
37
|
+
{"pixel_values": Image(), "label": Image()}
|
|
38
|
+
), # Example shape
|
|
37
39
|
)
|
|
38
40
|
|
|
39
41
|
if transforms is not None:
|
|
@@ -127,14 +127,16 @@ def train_segformer_semantic_segmentation_model(
|
|
|
127
127
|
|
|
128
128
|
# Create datasets for the model.
|
|
129
129
|
train_dataset = create_segformer_segmentation_dataset(
|
|
130
|
-
train_data, transforms=train_transforms
|
|
130
|
+
train_data.copy(), transforms=train_transforms
|
|
131
131
|
)
|
|
132
132
|
|
|
133
133
|
val_dataset = create_segformer_segmentation_dataset(
|
|
134
134
|
(
|
|
135
|
-
val_data
|
|
135
|
+
val_data.copy()
|
|
136
136
|
if max_val_size is None
|
|
137
|
-
else val_data.sample(
|
|
137
|
+
else val_data.sample(
|
|
138
|
+
n=max_val_size, random_state=random_state
|
|
139
|
+
).copy()
|
|
138
140
|
),
|
|
139
141
|
transforms=val_transforms,
|
|
140
142
|
)
|
|
@@ -241,7 +243,7 @@ def train_segformer_semantic_segmentation_model(
|
|
|
241
243
|
model = trainer.model
|
|
242
244
|
|
|
243
245
|
dataset = create_segformer_segmentation_dataset(
|
|
244
|
-
train_data, transforms=val_transforms
|
|
246
|
+
train_data.copy(), transforms=val_transforms
|
|
245
247
|
)
|
|
246
248
|
results["train"]["metrics"] = per_class_dice_on_dataset(
|
|
247
249
|
model,
|
|
@@ -254,7 +256,7 @@ def train_segformer_semantic_segmentation_model(
|
|
|
254
256
|
)
|
|
255
257
|
|
|
256
258
|
dataset = create_segformer_segmentation_dataset(
|
|
257
|
-
val_data, transforms=val_transforms
|
|
259
|
+
val_data.copy(), transforms=val_transforms
|
|
258
260
|
)
|
|
259
261
|
results["val"]["metrics"] = per_class_dice_on_dataset(
|
|
260
262
|
model,
|
|
@@ -270,7 +272,7 @@ def train_segformer_semantic_segmentation_model(
|
|
|
270
272
|
results["test"] = {}
|
|
271
273
|
|
|
272
274
|
dataset = create_segformer_segmentation_dataset(
|
|
273
|
-
test_data, transforms=val_transforms
|
|
275
|
+
test_data.copy(), transforms=val_transforms
|
|
274
276
|
)
|
|
275
277
|
results["test"]["metrics"] = per_class_dice_on_dataset(
|
|
276
278
|
model,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: dsa_helpers
|
|
3
|
-
Version: 1.1.5.
|
|
3
|
+
Version: 1.1.5.dev2
|
|
4
4
|
Summary: Utility functions for working with the DSA girder client.
|
|
5
5
|
Author-email: "Juan C. Vizcarra" <jvizcar@emory.edu>
|
|
6
6
|
Maintainer-email: "Juan C. Vizcarra" <jvizcar@emory.edu>
|
|
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
|
{dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/dash/dash_paperdragon_utils.py
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
|
{dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/object_detection/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/object_detection/tile_image.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{dsa_helpers-1.1.5.dev0 → dsa_helpers-1.1.5.dev2}/dsa_helpers/ml/transforms/segformer_transforms.py
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
|