dsa-helpers 1.1.5.dev3__tar.gz → 1.1.5.dev5__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.dev3/dsa_helpers.egg-info → dsa_helpers-1.1.5.dev5}/PKG-INFO +1 -1
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/__init__.py +1 -1
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/datasets/SegFormerSegmentationDataset.py +1 -1
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/datasets/utils.py +0 -2
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/segformer_semantic_segmentation/train.py +5 -16
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5/dsa_helpers.egg-info}/PKG-INFO +1 -1
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/pyproject.toml +1 -1
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/.gitignore +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/.readthedocs.yaml +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/LICENSE +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/README.md +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/app.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dev.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/docs/requirements.txt +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/docs/source/conf.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/docs/source/index.rst +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/cli_utils.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/dash/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/dash/dash_paperdragon_utils.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/dash/header.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/dash/header_callbacks.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/girder_utils.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/gpd_utils.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/image_utils.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/imread.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/imwrite.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/callbacks.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/datasets/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/evaluate.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/metrics.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/object_detection/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/object_detection/get_pearce_roi_images.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/object_detection/tile_image.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/object_detection/utils.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/segformer_semantic_segmentation/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/segformer_semantic_segmentation/inference.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/transforms/__init__.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/transforms/segformer_transforms.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/mongo_utils.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/tile_utils.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/tiling.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/utils.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers.egg-info/SOURCES.txt +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers.egg-info/dependency_links.txt +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers.egg-info/requires.txt +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers.egg-info/top_level.txt +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/setup.cfg +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/tests/app/Dockerfile +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/tests/app/app.py +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/tests/docker-compose.yaml +0 -0
- {dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/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.dev5
|
|
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>
|
|
@@ -19,7 +19,7 @@ class SegFormerSegmentationDataset(Dataset):
|
|
|
19
19
|
"""
|
|
20
20
|
self.image_files = df["fp"].tolist()
|
|
21
21
|
self.mask_files = df["mask_fp"].tolist()
|
|
22
|
-
self.df = df
|
|
22
|
+
self.df = df # store potential metadata
|
|
23
23
|
|
|
24
24
|
def __len__(self):
|
|
25
25
|
return len(self.image_files)
|
|
@@ -41,7 +41,7 @@ def train_segformer_semantic_segmentation_model(
|
|
|
41
41
|
Args:
|
|
42
42
|
save_dir (str): Directory where model checkpoint directory will
|
|
43
43
|
be saved to.
|
|
44
|
-
|
|
44
|
+
train_csv_fp (str): Train data, should be a pandas
|
|
45
45
|
dataframe or a path to a csv file containing the train data.
|
|
46
46
|
Must have the "fp" and "mask_fp" columns, which are the
|
|
47
47
|
filepaths to the images and masks, respectively.
|
|
@@ -71,6 +71,7 @@ def train_segformer_semantic_segmentation_model(
|
|
|
71
71
|
will be used. Defaults to None. Note that there is a bug
|
|
72
72
|
that this value must be kept short otherwise a cuda memory
|
|
73
73
|
error will occur.
|
|
74
|
+
|
|
74
75
|
random_state (int, optional): Random state for the validation
|
|
75
76
|
split. Defaults to 42.
|
|
76
77
|
tile_size (int, optional): Size of the tiles to use for the model.
|
|
@@ -240,15 +241,9 @@ def train_segformer_semantic_segmentation_model(
|
|
|
240
241
|
# For each of the datasets provided, get the metrics.
|
|
241
242
|
model = trainer.model
|
|
242
243
|
|
|
243
|
-
del train_dataset
|
|
244
|
-
del val_dataset
|
|
245
|
-
|
|
246
|
-
dataset = create_segformer_segmentation_dataset(
|
|
247
|
-
train_data, transforms=val_transforms
|
|
248
|
-
)
|
|
249
244
|
results["train"]["metrics"] = per_class_dice_on_dataset(
|
|
250
245
|
model,
|
|
251
|
-
|
|
246
|
+
train_data,
|
|
252
247
|
label2id,
|
|
253
248
|
batch_size=batch_size,
|
|
254
249
|
device=device,
|
|
@@ -256,12 +251,9 @@ def train_segformer_semantic_segmentation_model(
|
|
|
256
251
|
tqdm_notebook=tqdm_notebook,
|
|
257
252
|
)
|
|
258
253
|
|
|
259
|
-
dataset = create_segformer_segmentation_dataset(
|
|
260
|
-
val_data, transforms=val_transforms
|
|
261
|
-
)
|
|
262
254
|
results["val"]["metrics"] = per_class_dice_on_dataset(
|
|
263
255
|
model,
|
|
264
|
-
|
|
256
|
+
val_data,
|
|
265
257
|
label2id,
|
|
266
258
|
batch_size=batch_size,
|
|
267
259
|
device=device,
|
|
@@ -272,12 +264,9 @@ def train_segformer_semantic_segmentation_model(
|
|
|
272
264
|
if test_data is not None:
|
|
273
265
|
results["test"] = {}
|
|
274
266
|
|
|
275
|
-
dataset = create_segformer_segmentation_dataset(
|
|
276
|
-
test_data, transforms=val_transforms
|
|
277
|
-
)
|
|
278
267
|
results["test"]["metrics"] = per_class_dice_on_dataset(
|
|
279
268
|
model,
|
|
280
|
-
|
|
269
|
+
test_data,
|
|
281
270
|
label2id,
|
|
282
271
|
batch_size=batch_size,
|
|
283
272
|
device=device,
|
|
@@ -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.dev5
|
|
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.dev3 → dsa_helpers-1.1.5.dev5}/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
|
{dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/dsa_helpers/ml/object_detection/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{dsa_helpers-1.1.5.dev3 → dsa_helpers-1.1.5.dev5}/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.dev3 → dsa_helpers-1.1.5.dev5}/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
|