Skip to content

Commit b8d50fe

Browse files
Merge pull request #1 from USDA-REE-NASS/update2024
Update2024
2 parents d331813 + b20c036 commit b8d50fe

19 files changed

+1852
-1944
lines changed
Original file line numberDiff line numberDiff line change
@@ -1,34 +1,34 @@
1-
import os
2-
import sys
3-
import datetime as dt
4-
import configparser
5-
import subprocess
6-
import multiprocessing
7-
import importlib # CSB-Run util functions
8-
utils = importlib.import_module('CSB-Run.utils')
9-
10-
11-
# get command line args, 3 minimum required, missing args None
12-
# input args: workflow, startYear and endYear
13-
args = utils.GetArgs(sys.argv)
14-
15-
# get CSB-Run config file, default csb_default.ini
16-
print(f'Config file: {os.getcwd()}/config/csb_default.ini')
17-
cfg = utils.GetConfig('default')
18-
19-
# set parameters for CSB-Run
20-
# cpu_count = utils.GetBatch( args[0], args[3] )
21-
# #workflow #batchSize
22-
python_path,\
23-
script,\
24-
creation_dir,\
25-
partial = utils.SetRunParams(cfg, args)
26-
27-
28-
# build the folders for csb creation/prep run
29-
run_dir = utils.BuildFolders(creation_dir, args[0])
30-
#workflow
31-
32-
# run the CSB workflow script
33-
p = subprocess.run([python_path, script, args[1], args[2], run_dir, str(partial)])
34-
#startYear #endYear
1+
import os
2+
import sys
3+
import datetime as dt
4+
import configparser
5+
import subprocess
6+
import multiprocessing
7+
import importlib # CSB-Run util functions
8+
utils = importlib.import_module('CSB-Run.utils')
9+
10+
11+
# get command line args, 3 minimum required, missing args None
12+
# input args: workflow, startYear and endYear
13+
args = utils.GetArgs(sys.argv)
14+
15+
# get CSB-Run config file, default csb_default.ini
16+
print(f'Config file: {os.getcwd()}/config/csb_default.ini')
17+
cfg = utils.GetConfig('default')
18+
19+
# set parameters for CSB-Run
20+
# cpu_count = utils.GetBatch( args[0], args[3] )
21+
# #workflow #batchSize
22+
python_path,\
23+
script,\
24+
creation_dir,\
25+
partial = utils.SetRunParams(cfg, args)
26+
27+
28+
# build the folders for csb creation/prep run
29+
run_dir = utils.BuildFolders(creation_dir, args[0])
30+
#workflow
31+
32+
# run the CSB workflow script
33+
p = subprocess.run([python_path, script, args[1], args[2], run_dir, str(partial)])
34+
#startYear #endYear

csb-project/CSB-Run/CSB-Run/CSB-create.py CSB-Run/CSB-Run/CSB-create.py

+603-431
Large diffs are not rendered by default.

csb-project/CSB-Run/CSB-Run/CSB-distribute.py CSB-Run/CSB-Run/CSB-distribute.py

+373-349
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)