Commit 9e05aca5 authored by Philippe Delandmeter's avatar Philippe Delandmeter
Browse files

netcdf_to_msh now writes idx file

parent 985fcaec
Pipeline #1348 passed with stage
in 29 minutes
......@@ -403,14 +403,18 @@ def netcdf_to_msh(mesh_file_name, nc_file_name, variable_name, export_file_name,
* variable_name
name of the variable in the netcdf file
* export_file_name
path to the field name (.msh format)
path to the field name (.idx format)
* time
time at which the data will be exported in msh format (default: 0)
"""
groups = dgpy.dgGroupCollection(mesh_file_name)
f = slim_private._load_function((nc_file_name,variable_name),groups)
dgpy.function.getTime().set(time)
groups.exportFunctionMsh(f, export_file_name)
dof = dgpy.dgDofContainer(groups, 1)
dof.interpolate(f)
exporter = dgpy.dgIdxExporter(dof, export_file_name)
exporter.exportIdx()
#groups.exportFunctionMsh(f, export_file_name)
def read_temporal_serie(file_name, time=None, output_netcdf=None):
"""Return a temporal serie from a text data file.
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment