Skip to content

Commit

Permalink
Add link to validation data
Browse files Browse the repository at this point in the history
  • Loading branch information
constantinpape committed Feb 28, 2020
1 parent c0b8ee9 commit ad248b6
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 5 deletions.
1 change: 1 addition & 0 deletions data/1.0.0/README.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Contains all data in the resource at publication of the preprint.
2 changes: 2 additions & 0 deletions segmentation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,5 @@ Training data and weights for the 3d U-Nets are available on zenodo:
- nuclei: [Training Data](https://zenodo.org/record/3675220/files/nuclei.zip?download=1), [Weights](https://zenodo.org/record/3675288/files/nuclei.nn?download=1)

The ilastik project and training data for the chromatin segmentation are also [available on zenodo](https://doi.org/10.5281/zenodo.3676534), as well as the [ilastik projects for carving out tissue/body parts and the animal outline](https://doi.org/10.5281/zenodo.3678793).

In addition, we provide scripts to validate cell and nucleus segmentations. The validation data, which consists of annotations for nuclei and cell soma from 8 domain experts, [is available on zenodo](https://doi.org/10.5281/zenodo.3690727).
12 changes: 7 additions & 5 deletions segmentation/validation/eval_cell_segmentation.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ def get_label_ids(path, key):
return label_ids


def compute_baseline_tables(version):
def compute_baseline_tables(version, target, max_jobs):
path = BASELINE_ROOT
folder = os.path.join(ROOT, version, 'images', 'local')
for name in BASELINE_NAMES:
Expand All @@ -38,7 +38,7 @@ def compute_baseline_tables(version):
write_default_global_config(config_folder)
label_ids = get_label_ids(path, key)
region_attributes(path, out_path, folder, label_ids,
tmp_folder, target='local', max_jobs=48,
tmp_folder, target=target, max_jobs=max_jobs,
key_seg=key)


Expand All @@ -60,9 +60,9 @@ def eval_seg(version):
print("Total number of annotations:", tot)


def eval_baselines(version):
def eval_baselines(version, target, max_jobs):
print("Computing region tables ...")
compute_baseline_tables(version)
compute_baseline_tables(version, target, max_jobs)

path = BASELINE_ROOT
results = {}
Expand All @@ -88,6 +88,8 @@ def main():
parser.add_argument("--version", type=str, default='', help="Version to evaluate.")
parser.add_argument("--baselines", type=int, default=0,
help="Whether to evaluate the baseline segmentations")
parser.add_argument('--target', type=str, default='local')
parser.add_argument('--max_jobs', type=int, default=48)
args = parser.parse_args()

version = args.version
Expand All @@ -97,7 +99,7 @@ def main():
baselines = bool(args.baselines)
if baselines:
print("Evaluatiing baselines")
eval_baselines(version)
eval_baselines(version, args.target, args.max_jobs)
else:
print("Evaluating segmentation for version", version)
eval_seg(version)
Expand Down

0 comments on commit ad248b6

Please sign in to comment.