Commit 84f77c8 1 parent 700eee0 commit 84f77c8 Copy full SHA for 84f77c8
File tree 1 file changed +2
-7
lines changed
1 file changed +2
-7
lines changed Original file line number Diff line number Diff line change 1
1
"""Example to import datasets into Cytomine."""
2
2
3
3
import logging
4
- import os
5
4
import sys
6
5
from argparse import ArgumentParser
7
6
31
30
)
32
31
parser .add_argument (
33
32
"--path" ,
34
- help = "The path to the datasets to import" ,
33
+ default = "/dataset" ,
34
+ help = "The path specified in DATASET_PATH environment variable" ,
35
35
)
36
36
params , _ = parser .parse_known_args (sys .argv [1 :])
37
37
40
40
public_key = params .public_key ,
41
41
private_key = params .private_key ,
42
42
) as cytomine :
43
-
44
- # Check that the datasets path exists on your file system
45
- if not os .path .exists (params .path ):
46
- raise ValueError (f"{ params .path } does not exist!" )
47
-
48
43
# To import the datasets, we need to know the ID of your Cytomine storage.
49
44
storages = StorageCollection ().fetch ()
50
45
storage = next (
You can’t perform that action at this time.
0 commit comments