edmundmiller commited on
Commit
fed1c09
·
unverified ·
1 Parent(s): 3384edf

fix: Make results before writing to it

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -26,6 +26,10 @@ anchors = snapshot_download(
26
  )
27
  HiCorr_data = snapshot_download("funlab/HiCorr_test_data", repo_type="dataset")
28
 
 
 
 
 
29
  predict_and_write(
30
  model,
31
  full_matrix_dir=HiCorr_data + f"/anchor_2_anchor.loop.{chromosome}",
@@ -42,7 +46,6 @@ predict_and_write(
42
  )
43
 
44
  # Print and list the files
45
- import os
46
 
47
  st.write("Files created:")
48
  st.write(os.listdir("results"))
 
26
  )
27
  HiCorr_data = snapshot_download("funlab/HiCorr_test_data", repo_type="dataset")
28
 
29
+ import os
30
+
31
+ os.makedirs("results", exist_ok=True)
32
+
33
  predict_and_write(
34
  model,
35
  full_matrix_dir=HiCorr_data + f"/anchor_2_anchor.loop.{chromosome}",
 
46
  )
47
 
48
  # Print and list the files
 
49
 
50
  st.write("Files created:")
51
  st.write(os.listdir("results"))