Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -50,11 +50,8 @@ def make_scaffold_motifs(pdb_code, start_idx, end_idx, scaffold_length, model_ty
|
|
50 |
checkpoint = OA_DM_38M()
|
51 |
model, collater, tokenizer, scheme = checkpoint
|
52 |
data_top_dir = '/home/user/.cache/huggingface/datasets/'
|
53 |
-
|
54 |
-
# print("Folders in Current Directory:", os.listdir())
|
55 |
-
# print("Folders in User Directory:", os.listdir("/home/user/"))
|
56 |
# print("Folders in User Cache Directory:", os.listdir("/home/user/.cache"))
|
57 |
-
print("Folders in User Directory:", [ f.path for f in os.scandir("/home/user/") if f.is_dir() ])
|
58 |
start_idx = list(map(int, start_idx.strip('][').split(',')))
|
59 |
end_idx = list(map(int, end_idx.strip('][').split(',')))
|
60 |
generated_sequence, new_start_idx, new_end_idx = generate_scaffold(model, pdb_code, start_idx, end_idx, scaffold_length, data_top_dir, tokenizer, device='cpu')
|
|
|
50 |
checkpoint = OA_DM_38M()
|
51 |
model, collater, tokenizer, scheme = checkpoint
|
52 |
data_top_dir = '/home/user/.cache/huggingface/datasets/'
|
53 |
+
os.makedirs(data_top_dir, exist_ok=True)
|
|
|
|
|
54 |
# print("Folders in User Cache Directory:", os.listdir("/home/user/.cache"))
|
|
|
55 |
start_idx = list(map(int, start_idx.strip('][').split(',')))
|
56 |
end_idx = list(map(int, end_idx.strip('][').split(',')))
|
57 |
generated_sequence, new_start_idx, new_end_idx = generate_scaffold(model, pdb_code, start_idx, end_idx, scaffold_length, data_top_dir, tokenizer, device='cpu')
|