Browse Source

[Exp] Update exceptions in fcsp exps.

v0.2.x
jajupmochi 4 years ago
parent
commit
81a881bd79
1 changed files with 6 additions and 5 deletions
  1. +6
    -5
      gklearn/experiments/thesis/graph_kernels/fcsp/run_jobs_compare_fcsp_space.py

+ 6
- 5
gklearn/experiments/thesis/graph_kernels/fcsp/run_jobs_compare_fcsp_space.py View File

@@ -210,11 +210,12 @@ def check_task_status(save_dir, *params):

# Check if the task is already computed.
file_name = os.path.join(save_dir, 'space' + str_task_id + '.pkl')
if os.path.isfile(file_name):
with open(file_name, 'rb') as f:
data = pickle.load(f)
if data['completed']:
return True
if os.path.getsize(file_name) > 0:
if os.path.isfile(file_name):
with open(file_name, 'rb') as f:
data = pickle.load(f)
if data['completed']:
return True

return False



Loading…
Cancel
Save