Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

large variable/file support in MpasMeshConverter.x #465

Open
xtian15 opened this issue May 23, 2022 · 4 comments
Open

large variable/file support in MpasMeshConverter.x #465

xtian15 opened this issue May 23, 2022 · 4 comments

Comments

@xtian15
Copy link

xtian15 commented May 23, 2022

I recently used jigsaw to generate a mesh of 10-30 million cells. When trying to write them out at netcdf formats using MpasMeshConverter.x, the job was terminated due to size limits imposed by netcdf referenced by the executable. In this case, is there anything that can be done to lift this limit inside the MpasMeshConverter.x? Thanks!

Build areaCell, areaTriangle, and kiteAreasOnVertex.
     Found 0 incomplete cells. Each is marked with an area of -1.
Build edgesOnEdge and weightsOnEdge.
Build angleEdge.
Building mesh qualities.
        Mesh contains: 0 obtuse triangles.
Writing grid dimensions
Writing grid attributes
Writing grid coordinates
Writing cell connectivity
Writing edge connectivity
Writing vertex connectivity
Writing cell parameters
Writing edge parameters
Writing vertex parameters
NetCDF: One or more variable sizes violate format constraints
NetCDF: One or more variable sizes violate format constraints
Error - 2
Traceback (most recent call last):
  File "/backup/xtian/cases/meshes/mesh-gen/gen-mesh-cellWidth.py", line 132, in <module>
    meshShapeFile(dMin=dMin, dMax=dMax)
  File "/backup/xtian/cases/meshes/mesh-gen/gen-mesh-cellWidth.py", line 117, in meshShapeFile
    cellWidth2mesh(lat, lon, cellWidth, output=gridname)
  File "/backup/xtian/cases/meshes/mesh-gen/gen-mesh-cellWidth.py", line 41, in cellWidth2mesh
    convert(xarray.open_dataset(out_basepath+'_triangles.nc'),
  File "/backup/miniconda3/envs/xtian-mpas-tools/lib/python3.10/site-packages/mpas_tools/mesh/conversion.py", line 51, in convert
    _call_subprocess(['MpasMeshConverter.x', inFileName, outFileName],
  File "/backup/miniconda3/envs/xtian-mpas-tools/lib/python3.10/site-packages/mpas_tools/mesh/conversion.py", line 219, in _call_subprocess
    subprocess.check_call(args)
  File "/backup/miniconda3/envs/xtian-mpas-tools/lib/python3.10/subprocess.py", line 369, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command '['MpasMeshConverter.x', '/backup/xtian/cases/meshes/mesh-gen/VR-004-060/tmpp82hzxq1/mesh_in.nc', '/backup/xtian/cases/meshes/mesh-gen/VR-004-060/tmpp82hzxq1/mesh_out.nc']' returned non-zero exit status 2.
@xylar
Copy link
Collaborator

xylar commented May 24, 2022

@xtian15, this is a big issue, I agree. I've run into this as well.

The problem is that the mesh conversion tools were build with the legacy NetCDF c++ library that hasn't gotten any further attention. The syntax for the "proper" NetCDF c++ library is totally different and would require a significant rewrite of the tools that we don't have staff time for, at least not a LANL.

@xylar
Copy link
Collaborator

xylar commented May 24, 2022

@mgduda, is this anything you guys at NCAR have resources to work on?

@xtian15
Copy link
Author

xtian15 commented May 24, 2022

  1. Any plans to remedy this limitation in the near future?
  2. Is there any workaround when you encountered this issue?
    Thanks!

@xylar
Copy link
Collaborator

xylar commented May 24, 2022

I'm not aware of a workaround. I ended abandoning a large MPAS-Ocean mesh I was trying to work on because of this.

There is also not any concrete plan to address this from the LANL side. Let's see what @mgduda has to say.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants