andreped commited on
Commit
5f6ee91
1 Parent(s): ad1ce7c

added checks

Browse files
Files changed (1) hide show
  1. livermask/livermask.py +4 -0
livermask/livermask.py CHANGED
@@ -144,6 +144,10 @@ def main():
144
  # Memory growth must be set before GPUs have been initialized
145
  print(e)
146
 
 
 
 
 
147
  if not ret.input.endswith(".nii"):
148
  raise ValueError("Image provided is not in the supported '.nii' format.")
149
  if not ret.output.endswith(".nii"):
 
144
  # Memory growth must be set before GPUs have been initialized
145
  print(e)
146
 
147
+ if ret.input is None:
148
+ raise ValueError("Please, provide an input.")
149
+ if ret.output is None:
150
+ raise ValueError("Please, provide an output.")
151
  if not ret.input.endswith(".nii"):
152
  raise ValueError("Image provided is not in the supported '.nii' format.")
153
  if not ret.output.endswith(".nii"):