For a given date, Sc/Planet, magnetogram type, write all connected, open and close fieldlines into 3 different ascii files.
More...
|
tuple | log_id = module_io.open_log(__file__) |
|
tuple | time_0 = datetime.datetime.today() |
|
string | help_message |
|
string | scraft = 'PSP' |
|
tuple | error_hmodel = module_io.check_hmodel(module_io.hmodel ) |
|
tuple | error_cmodel = module_io.check_cmodel(module_io.cmodel ) |
|
tuple | error_magtype = module_io.check_magtype(module_io.magtype) |
|
tuple | error_reftime = module_io.check_reftime(module_io.reftime) |
|
tuple | error_scraft = module_io.check_scraft(scraft) |
|
tuple | date_in = module_timespace.Time() |
|
tuple | results |
|
| present_folder = True |
|
string | launch_message = 'Should launch this command:\npython dir.main/connect_tool.py -hmodel %s -cmodel %s -reftime %s -magtype %s -sc %s -y %d -m %d -d %d -H %d' |
|
list | simu_db = results[0] |
|
tuple | folder_parent = os.path.join('dir.output','TMP') |
|
list | operation_mode = simu_db['operation_mode'] |
|
tuple | folder_output = module_io.output_localname(module_io.hmodel,module_io.cmodel,module_io.reftime,scraft,module_io.magtype,operation_mode,date_in.datetime) |
|
tuple | rand_int = str(int(random.uniform(0,1000))) |
|
tuple | path_output = os.path.join(folder_parent,folder_output) |
|
tuple | path_param = os.path.join(simu_db['dirname'],simu_db['file_parameter']) |
|
tuple | stream = open(path_param,'r') |
|
tuple | data_param = yaml.load(stream,Loader=yaml.FullLoader) |
|
tuple | path_fieldlines_connecttool = os.path.join(path_output,'fieldlines_ct.ascii') |
|
tuple | fieldlines_close = module_fieldline.closed_fieldline(fieldlines_bot) |
|
tuple | path_fieldlines_close = os.path.join(path_output,'fieldlines_close.ascii') |
|
tuple | path_fieldlines_open = os.path.join(path_output,'fieldlines_open.ascii') |
|
tuple | time_2 = datetime.datetime.today() |
|
For a given date, Sc/Planet, magnetogram type, write all connected, open and close fieldlines into 3 different ascii files.
Fetch the corresponding Connect-tool simulation and copy its fieldlines which are connected with the Sc/Planet.
Launch Corfield-PFSS on a defined grid, in bottom/top mode for close/open fieldlines.
- Author
- M. Indurain
- Date
- 2019
Input
Usage:
python full_sphere_fieldline.py -hmodel heliospheric_model -cmodel coronal_model -magtype magnetic_type -reftime reference_time -sc sc_name -y year -m month -d day -H hour
where:
- -h : brief help
- sc_name : SC/Planet name. PSP,STA,EARTH. Default PSP
- heliospheric_model : Heliospheric model, one of interface_heliosphere.info. Default PARKER.
- coronal_model : Coronal model, PFSS only.
- magnetic_type : Type of magnetic data. WSO,NSO,ADAPT for PFSS coronal model. Default WSO.
- reference_time : Referential time. SCTIME,SUNTIME. Default SCTIME.
- year : year in UTC. Default today UTC year.
- month : month in UTC. Default today UTC month.
- day : day in UTC. Default today UTC day.
- hour : hour in UTC. Default 0.