fatmacankara commited on
Commit
96fc37b
·
1 Parent(s): 1d9dfe8

Update ASCARIS.py

Browse files
Files changed (1) hide show
  1. ASCARIS.py +5 -5
ASCARIS.py CHANGED
@@ -13,7 +13,7 @@ import base64
13
  showWarningOnDirectExecution = False
14
 
15
  from huggingface_hub import hf_hub_download
16
- from huggingface_hub.utils import get_session, hf_raise_for_status, HfHubHTTPError
17
 
18
 
19
  import streamlit as st
@@ -21,12 +21,12 @@ import gzip
21
  try:
22
  x = hf_hub_download(repo_id="HuBioDataLab/AlphafoldStructures", filename=f"AF-Q9BSV6-F1-model_v4.pdb.gz",repo_type = 'dataset')
23
  st.write('1')
24
- except HfHubHTTPError:
25
  x = hf_hub_download(repo_id="HuBioDataLab/AlphafoldStructures2", filename=f"AF-Q9BSV6-F1-model_v4.pdb.gz",repo_type = 'dataset')
26
- st.write('1')
27
- except HfHubHTTPError:
28
  x = hf_hub_download(repo_id="HuBioDataLab/AlphafoldStructures3", filename=f"AF-Q9BSV6-F1-model_v4.pdb.gz",repo_type = 'dataset')
29
- st.write('1')
30
 
31
  def convert_df(df):
32
  return df.to_csv(index=False).encode('utf-8')
 
13
  showWarningOnDirectExecution = False
14
 
15
  from huggingface_hub import hf_hub_download
16
+ from huggingface_hub.utils import hf_raise_for_status, HfHubHTTPError
17
 
18
 
19
  import streamlit as st
 
21
  try:
22
  x = hf_hub_download(repo_id="HuBioDataLab/AlphafoldStructures", filename=f"AF-Q9BSV6-F1-model_v4.pdb.gz",repo_type = 'dataset')
23
  st.write('1')
24
+ except huggingface_hub.utils.EntryNotFoundError:
25
  x = hf_hub_download(repo_id="HuBioDataLab/AlphafoldStructures2", filename=f"AF-Q9BSV6-F1-model_v4.pdb.gz",repo_type = 'dataset')
26
+ st.write('2')
27
+ except huggingface_hub.utils.EntryNotFoundError:
28
  x = hf_hub_download(repo_id="HuBioDataLab/AlphafoldStructures3", filename=f"AF-Q9BSV6-F1-model_v4.pdb.gz",repo_type = 'dataset')
29
+ st.write('3')
30
 
31
  def convert_df(df):
32
  return df.to_csv(index=False).encode('utf-8')