Hello all,
I am trying to read data from (Index of /climate_environment/CDC/grids_germany/hourly/radolan/historical/asc/). I have downloaded the data to my local machine. For reference I am writing my code below in comments.
import os
import sys
import wradlib as wrl
import numpy as np
import warnings
warnings.filterwarnings("ignore")
os.environ["WRADLIB_DATA"] = "C:\\Users\Admin\wradlib-data-main"
filename = "Data/Firstyear/RW-200506.tar"
filename = wrl.util.get_wradlib_data_file(filename)
data_raw, meta = wrl.io.read_radolan_composite(filename)
When running the file this is the error I am facing:
runfile(‘D:/Sandeep/Thesis/thesis.py’, wdir=‘D:/Sandeep/Thesis’)
Traceback (most recent call last):
File “C:\ProgramData\Anaconda3\envs\wradlib\lib\site-packages\spyder_kernels\py3compat.py”, line 356, in compat_exec
exec(code, globals, locals)
File “d:\sandeep\thesis\thesis.py”, line 19, in
data_raw, meta = wrl.io.read_radolan_composite(filename)
File “C:\ProgramData\Anaconda3\envs\wradlib\lib\site-packages\wradlib\io\radolan.py”, line 763, in read_radolan_composite
attrs = radfile.attrs
File “C:\ProgramData\Anaconda3\envs\wradlib\lib\site-packages\wradlib\io\radolan.py”, line 1000, in attrs
self._attrs = self._read_attrs()
File “C:\ProgramData\Anaconda3\envs\wradlib\lib\site-packages\wradlib\io\radolan.py”, line 1039, in _read_attrs
header = read_radolan_header(self.fp)
File “C:\ProgramData\Anaconda3\envs\wradlib\lib\site-packages\wradlib\io\radolan.py”, line 691, in read_radolan_header
header += str(mychar.decode())
UnicodeDecodeError: ‘utf-8’ codec can’t decode byte 0x8b in position 0: invalid start byte
More details:
- in python(version: 3.8.13) and wradlib (version: 1.13.0)