ESCOMP / ESCOMP/CTSM

mesh_maker doesn't work with surface dataset produced by subset_data

Open
#2,774 1 comment 0 reactions 0 assignees View on GitHub
bug test: python
Dominant language
Fortran
Stars
352
Forks
361
Avg merge
6d 6h
Merged PRs (30d)
8

Description

### General bug information

I'm not sure this is a problem, exactly—`subset_data` can produce a mesh file itself. But it's weird and could cause confusion.

(In fact, I'm not sure there's even a good use case for having a standalone `mesh_maker` that we need to support...)

**CTSM version you are using:** ctsm5.2.027

**Does this bug cause significantly incorrect results in the model's science?** No

**Configurations affected:** n/a

### Important details of your setup / configuration so we can reproduce the bug
```bash
infile=/glade/work/samrabin/fates_grids/shuman_southam_halfdeg_ctsm5.2.013_2000_noLU/surfdata_shuman_southam_halfdeg_ctsm5.2.013_2000_noLU_hist_2000_78pfts_c240827.nc
outfile=shuman_mesh_test_2d.nc
tools/site_and_regional/mesh_maker --input $infile --output $outfile --lon LATIXY --lat LONGXY
```

### Important output or errors that show the problem

```
WARNING: Corners have longitudes less than zero -- this will work, but may result in answers different to roundoff to corners within 0 to 360
ERROR: The size of unique coordinate pairs is 111 but expected size is 12321!
ERROR: Including a pole point in your grid is the usual reason for this problem
ERROR: Expected size for element connections is wrong
```

I think it should be easy enough to handle this—just generate the pairs from the unique values given (12321 = 111^2).

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.