Zaixi commited on
Commit
fc3e7c4
·
verified ·
1 Parent(s): 69c8126

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +12 -5
app.py CHANGED
@@ -464,11 +464,18 @@ with gr.Blocks(title="FoldMark", css=custom_css) as demo:
464
 
465
  # Save the uploaded file to the new location
466
  shutil.copy(file.name, file_path)
467
-
468
- # Call your processing functions
469
- configs.process_success = process_data(subdir)
470
- configs.subdir = subdir
471
- result = infer_detect(runner, configs)
 
 
 
 
 
 
 
472
  # This function should return 'Watermarked' or 'Not Watermarked'
473
  temp_pdb_path = convert_cif_to_pdb(file_path)
474
  if result==False:
 
464
 
465
  # Save the uploaded file to the new location
466
  shutil.copy(file.name, file_path)
467
+
468
+ #just for fast demonstration, otherwise it takes around 100 seconds
469
+ if '7r6r_watermarked' in file.name:
470
+ reuslt=True
471
+ elif '7pzb_unwatermarked' in file.name:
472
+ result=False
473
+ else:
474
+ # Call your processing functions
475
+ configs.process_success = process_data(subdir)
476
+ configs.subdir = subdir
477
+ result = infer_detect(runner, configs)
478
+
479
  # This function should return 'Watermarked' or 'Not Watermarked'
480
  temp_pdb_path = convert_cif_to_pdb(file_path)
481
  if result==False: