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

Issue with rioxarray==0.15.6 #215

Open
Skealz opened this issue Jun 24, 2024 · 0 comments
Open

Issue with rioxarray==0.15.6 #215

Skealz opened this issue Jun 24, 2024 · 0 comments

Comments

@Skealz
Copy link
Collaborator

Skealz commented Jun 24, 2024

Downgrading to rioxarray==0.15.5 makes it work.

24/06/2024 18:35:38 INFO main.py(38) input file: /home/datawork-cersat-public/project/mpc-sentinel1/data/esa/sentinel-1b/L1/IW/S1B_IW_GRDH_20:39:41 [369/1993]GRDH_1SDV_20211102T154832_20211102T154857_029411_038293_D8E0.SAFE                                                                                             
24/06/2024 18:35:39 INFO inversion.py(600) recalibration is False : Kersten formula is not applied                                                            
24/06/2024 18:35:39 INFO utils.py(479) BlockingActorProxy: Transparent proxy for from_dict                                                                    
/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/python3.
10/site-packages/numpy/core/numeric.py:407: RuntimeWarning: invalid value encountered in cast                                                                 
  multiarray.copyto(res, fill_value, casting='unsafe')                                                                                                        
24/06/2024 18:35:49 WARNING base_dataset.py(867) Raster variable are experimental                                                                             /home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/python3.10/site-packages/xarray/core/dataset.py:274: UserWarning: The specified chunks separate the stored chunks along dimension "time" starting at index 1. This could degrade performance. Instead, consider rechunking after loading.                                                                                           
  warnings.warn(                                                                                                                                              
24/06/2024 18:35:51 INFO inversion.py(631) Traceback (most recent call last):                                                                                 
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/
python3.10/site-packages/grdwindinversion/inversion.py", line 603, in makeL2                                                                                  
    xsar_dataset = fct_dataset(                                                                                                                               
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/python3.10/site-packages/xsar/sentinel1_dataset.py", line 297, in __init__                                                                                    
    self.add_high_resolution_variables(                                                                                                                       
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/
python3.10/site-packages/xsar/sentinel1_dataset.py", line 533, in add_high_resolution_variables                                                                   rasters = self._load_rasters_vars()                                                                                                                       
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/
python3.10/site-packages/xsar/utils.py", line 95, in wrapper                                                                                                  
    result = f(*args, **kwargs)                                                                                                                                 File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/python3.10/site-packages/xsar/base_dataset.py", line 909, in _load_rasters_vars                                                                               
    reprojected_ds = self.map_raster(raster_ds).rename(                        
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/
python3.10/site-packages/xsar/utils.py", line 95, in wrapper                                                                                                  
    result = f(*args, **kwargs)                                                
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/
python3.10/site-packages/xsar/base_dataset.py", line 859, in map_raster                                                                                       
    return self._set_rio(mapped_ds)                                            
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/
python3.10/site-packages/xsar/base_dataset.py", line 267, in _set_rio                                                                                             ds[v] = ds[v].rio.write_gcps(                                              
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/
python3.10/site-packages/rioxarray/rioxarray.py", line 1242, in write_gcps                                                                                    
    data_obj.coords[grid_mapping_name].attrs["gcps"] = json.dumps(geojson_gcps) 
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/
python3.10/json/__init__.py", line 231, in dumps                                                                                                                  return _default_encoder.encode(obj)                                                                                                                       
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/
python3.10/json/encoder.py", line 199, in encode                                                                                                              
    chunks = self.iterencode(o, _one_shot=True)                                                                                                               
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/
python3.10/json/encoder.py", line 257, in iterencode                                                                                                          
    return _iterencode(o, 0)                                                                                                                                  
  File "/home/datawork-cersat-public/cache/project/sarwing/commits/2024v6v24_1v0_0v2v3vpost10_1v0v8_1v0v6_1v0v6_1v1v11_1v0v2_1v0v1_1v2v0/grdwindinversion/lib/
python3.10/json/encoder.py", line 179, in default                                                                                                             
    raise TypeError(f'Object of type {o.__class__.__name__} '                                                                                                 
TypeError: Object of type int64 is not JSON serializable                                                                                                      
                                                                                                                                                              
24/06/2024 18:35:51 ERROR inversion.py(632) Object of type int64 is not JSON serializable
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

1 participant