-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathpreprocessor.py
41 lines (34 loc) · 1.1 KB
/
preprocessor.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
import os
def create_edge_directories():
"""
Create the necessary EDGE framework directories if they don't exist.
"""
# List of subdirectories for "results" and "data"
sub_dirs = [
"results",
"data",
"data/KGs",
"results/dataframes",
"results/evaluations",
"results/exp_visualizations",
"results/predictions",
"results/predictions/CELOE",
"results/predictions/EvoLearner",
"results/predictions/PGExplainer",
"results/predictions/SubGraphX",
"results/evaluations/CELOE",
"results/evaluations/EvoLearner",
"results/evaluations/PGExplainer",
"results/evaluations/SubGraphX",
]
# Function to create directories if they don't exist
def create_directories(dirs):
for dir in dirs:
if not os.path.exists(dir):
os.makedirs(dir)
print(f"Created directory: {dir}")
else:
print(f"Directory already exists: {dir}")
# Create the directories
create_directories(sub_dirs)
create_edge_directories()