|
22 | 22 | def make_bcs_ease(config): |
23 | 23 | bin_dir = os.getcwd() |
24 | 24 | if '/bin' not in bin_dir: |
25 | | - print("please run this program in installed bin directory") |
26 | | - return |
| 25 | + print(" ") |
| 26 | + print("******************************************************************") |
| 27 | + print("ERROR: Must run this program in installed bin directory. ") |
| 28 | + print("******************************************************************") |
| 29 | + return |
27 | 30 |
|
28 | 31 | grid_type = config['grid_type'] |
| 32 | + resolution = config['resolution'] |
| 33 | + GRIDNAME = grid_type+'_'+ resolution |
| 34 | + |
29 | 35 | if 'EASEv' not in grid_type : |
30 | | - print('This is not a EASE grid') |
| 36 | + print(" ") |
| 37 | + print("******************************************************************") |
| 38 | + print("ERROR: " + GRIDNAME + " is not an EASE grid. ") |
| 39 | + print("******************************************************************") |
31 | 40 | return |
32 | 41 |
|
33 | | - resolution = config['resolution'] |
| 42 | + # if resolution is M01 in EASEv1 or EASEv2, do not execute |
| 43 | + # Instead, exist and print an on-screen message to the user |
| 44 | + if resolution == "M01": |
| 45 | + print(" ") |
| 46 | + print("******************************************************************") |
| 47 | + print("WARNING: Job for " + GRIDNAME + " not submitted! ") |
| 48 | + print(" EASEv[x]_M01 (~1 km) resolution requires custom process. ") |
| 49 | + print(" Contact GMAO Land Group for assistance. ") |
| 50 | + print("******************************************************************") |
| 51 | + print(" ") |
| 52 | + return |
34 | 53 |
|
35 | | - GRIDNAME = grid_type+'_'+ resolution |
36 | 54 | now = datetime.now() |
37 | 55 | tmp_dir = now.strftime("%Y%m%d%H%M%S") |
38 | 56 | tmp_dir = f"{resolution}_{tmp_dir}" |
|
0 commit comments