Skip to content

Commit 1be1cb1

Browse files
committed
Fix floor length check
1 parent 5cdcadb commit 1be1cb1

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

MLStructFP_benchmarks/utils/_fp_db.py

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,11 @@ def process_dataset(
132132
'respectively')
133133
assert '/' in path, path_err
134134

135-
t = len(db.floors)
135+
t: int = len(db.floors) # Total floors
136+
if t == 0:
137+
print('There are no floors. Process finished')
138+
return []
139+
136140
print(f'Total floors to compute in parallel: {t}')
137141
print(f'Using up to {num_proc}/{cpu_count()} CPUs')
138142
print(f'Using export path: {path}, image size: {isz}px, patch size: {psz}m')

0 commit comments

Comments
 (0)