File tree Expand file tree Collapse file tree 3 files changed +21
-5
lines changed Expand file tree Collapse file tree 3 files changed +21
-5
lines changed Original file line number Diff line number Diff line change 1
- v23.0.7
1
+ v23.0.8
Original file line number Diff line number Diff line change @@ -37,6 +37,7 @@ The GUI allows you to set the training parameters and generate and run the requi
37
37
- [ No module called tkinter] ( #no-module-called-tkinter )
38
38
- [ SDXL training] ( #sdxl-training )
39
39
- [ Change History] ( #change-history )
40
+ - [ 2024/03/11 (v23.0.8)] ( #20240311-v2308 )
40
41
- [ 2024/03/11 (v23.0.7)] ( #20240311-v2307 )
41
42
- [ 2024/03/11 (v23.0.6)] ( #20240311-v2306 )
42
43
- [ 2024/03/11 (v23.0.5)] ( #20240311-v2305 )
@@ -366,6 +367,10 @@ The documentation in this section will be moved to a separate document later.
366
367
367
368
## Change History
368
369
370
+ ### 2024/03/11 (v23.0.8)
371
+
372
+ - Add the ability to create outout and logs folder if it does not exist
373
+
369
374
### 2024/03/11 (v23.0.7)
370
375
371
376
- Fix minor issues related to functions and file path
Original file line number Diff line number Diff line change @@ -1321,18 +1321,29 @@ def validate_paths(headless:bool = False, **kwargs):
1321
1321
1322
1322
if output_dir != None :
1323
1323
log .info (f"Validating output folder path { output_dir } existence..." )
1324
- if output_dir == "" or not os . path . exists ( output_dir ) :
1325
- log .error ("...output folder path is missing or invalid " )
1324
+ if output_dir == "" :
1325
+ log .error ("...output folder path is missing" )
1326
1326
return False
1327
+ elif not os .path .exists (output_dir ):
1328
+ try :
1329
+ os .makedirs (output_dir , exist_ok = True ) # Create the directory, no error if it already exists
1330
+ log .info (f"...created folder at { output_dir } " )
1331
+ except Exception as e :
1332
+ log .error (f"...failed to create output folder: { e } " )
1333
+ return False
1327
1334
else :
1328
1335
log .info ("...valid" )
1329
1336
1330
1337
if logging_dir != None :
1331
1338
if logging_dir != "" :
1332
1339
log .info (f"Validating logging folder path { logging_dir } existence..." )
1333
1340
if not os .path .exists (logging_dir ):
1334
- log .error ("...logging folder path is missing or invalid" )
1335
- return False
1341
+ try :
1342
+ os .makedirs (logging_dir , exist_ok = True ) # Create the directory, no error if it already exists
1343
+ log .info (f"...created folder at { logging_dir } " )
1344
+ except Exception as e :
1345
+ log .error (f"...failed to create logging folder: { e } " )
1346
+ return False
1336
1347
else :
1337
1348
log .info ("...valid" )
1338
1349
else :
You can’t perform that action at this time.
0 commit comments