VyLala commited on
Commit
9dd2023
·
verified ·
1 Parent(s): 909f1fb

Update pipeline.py

Browse files
Files changed (1) hide show
  1. pipeline.py +9 -9
pipeline.py CHANGED
@@ -445,9 +445,9 @@ def pipeline_with_gemini(accessions,stop_flag=None, niche_cases=None, save_df=No
445
  links = unique_preserve_order(links)
446
  acc_score["source"] = links
447
  else:
448
- try:
449
- temp_source = False
450
- if save_df is not None and not save_df.empty:
451
  print("save df not none")
452
  print(str(chunks_filename))
453
  print(str(all_filename))
@@ -478,11 +478,11 @@ def pipeline_with_gemini(accessions,stop_flag=None, niche_cases=None, save_df=No
478
  print("tempo source")
479
  #acc_score["source"] = [str(file_all_path), str(file_chunk_path)]
480
  temp_source = True
481
- else: # temporary
482
- print("tempo source")
483
  #acc_score["source"] = [str(file_all_path), str(file_chunk_path)]
484
- temp_source = True
485
- if temp_source:
486
  if doi != "unknown":
487
  link = 'https://doi.org/' + doi
488
  # get the file to create listOfFile for each id
@@ -524,8 +524,8 @@ def pipeline_with_gemini(accessions,stop_flag=None, niche_cases=None, save_df=No
524
  links = unique_preserve_order(links)
525
  acc_score["source"] = links
526
  except:
527
- print("except for source")
528
- acc_score["source"] = []
529
  # chunk_path = "/"+saveTitle+"_merged_document.docx"
530
  # all_path = "/"+saveTitle+"_all_merged_document.docx"
531
  # # if chunk and all output not exist yet
 
445
  links = unique_preserve_order(links)
446
  acc_score["source"] = links
447
  else:
448
+ try:
449
+ temp_source = False
450
+ if save_df is not None and not save_df.empty:
451
  print("save df not none")
452
  print(str(chunks_filename))
453
  print(str(all_filename))
 
478
  print("tempo source")
479
  #acc_score["source"] = [str(file_all_path), str(file_chunk_path)]
480
  temp_source = True
481
+ else: # temporary
482
+ print("tempo source")
483
  #acc_score["source"] = [str(file_all_path), str(file_chunk_path)]
484
+ temp_source = True
485
+ if temp_source:
486
  if doi != "unknown":
487
  link = 'https://doi.org/' + doi
488
  # get the file to create listOfFile for each id
 
524
  links = unique_preserve_order(links)
525
  acc_score["source"] = links
526
  except:
527
+ print("except for source")
528
+ acc_score["source"] = []
529
  # chunk_path = "/"+saveTitle+"_merged_document.docx"
530
  # all_path = "/"+saveTitle+"_all_merged_document.docx"
531
  # # if chunk and all output not exist yet