hydro_2_python
Parses a hydro input file into an astropy table.
- Synopsis:
This is a simple program which will parse a hydro input file into an astropy table that python can read in as a wind
Description:
The code attempts to work out if the input file is an hdf file or an ascii file. The hdf file is produced by default from zeus, and is much the easier option however the code will have a try and work out how the r and theta files are named using the ndf filename. In this initial incarnation, it only deals with r theta files, future iterations will deal with different dimensionalities, and coordinate types as and when it becomes necessary.
There are two subroutines, which deal with importing the data from either of the input file formats, and returning an indentical dictionary that the main routine can use.
- param filename of the input file - if missed out code:
will prompt for it
- returns:
an astropy formatted ascii file, containing r, theta, the three components of velocity, the temperature of each cell and the density.
Notes:
History: 15may nsh Coded
Functions
|
|
|