Comments (3)
Please provide a complete script that can reproduce the issue.
from geemap.
Having a netcdf file like in attachement (test_wu.nc):
nc_file = '.../test_wu.nc' #reading my nc file
ds = xr.open_dataset(nc_file) #opening using xarray
img=geemap.netcdf_to_ee(nc_file=nc_file, var_names='temperature', lon='lon', lat='lat') #conerting netcdf to ee
Error: The netCDF file is not a regular longitude/latitude grid
This error appear due to the geemap/geemap/common.py [line: 3262-3267]:
dim_lon = np.unique(np.ediff1d(lon_data))
dim_lat = np.unique(np.ediff1d(lat_data))
if (len(dim_lon) != 1) or (len(dim_lat) != 1):
print("The netCDF file is not a regular longitude/latitude grid")
return
The problem: when we use function np.unique(np.ediff1d(lon_data)), we get an array that has more than one element. Therefore there is an error about unregular grid. This is due to if state comparison applied to floating point numbers.
test_wu.zip
from geemap.
Sorry for the delay. This bug has been fixed in #1973
from geemap.
Related Issues (20)
- netcdf_to_ee code HOT 2
- No layer style UI for ee.ImageCollection
- Minor typo in "About" section of project homepage HOT 1
- View extent in cartoee module switched up HOT 4
- Histogram data output is empty when using a for loop HOT 5
- geemap.ee_to_pandas not available anymore? HOT 1
- Layer loading spinner proof-of-concept
- Change README from reStructureText to Markdown
- OEEL - Calling JavaScript functions from Python issue HOT 3
- shiny + geemap HOT 3
- Add functionality to load the overlay layer in the image_collection_gif
- GEE HTML Export error HOT 3
- Map object is not displaying HOT 2
- Unable to Render geemap Maps Correctly in Google Colab HOT 2
- cartoee issue HOT 3
- error with 'geemap.requireJS' HOT 5
- Error with import geemap on Jupyter Notebook HOT 3
- Cannot edit displayed speed unit "m/s" HOT 1
- geemap's add_data causes solara app to crash HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from geemap.