You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Running the nbar_SAFE() function in Windows results in the following error: rasterio._err.CPLE_OpenFailedError: Attempt to create new tiff file '...' failed in VSI_TIFFOpen().
After further investigation, I realized it is caused by a platform-dependent string parsing in nbar.py (the following line). filename = img_path.split("/")[-1].replace("jp2", "tif")
I would suggest a quick fix like this:
ifos.name=='nt': # Windowsdir_sep="\\"else: # Linux, macOS, and other platformsdir_sep="/"filename=img_path.split(dir_sep)[-1].replace("jp2", "tif")
The text was updated successfully, but these errors were encountered:
Running the
nbar_SAFE()
function in Windows results in the following error:rasterio._err.CPLE_OpenFailedError: Attempt to create new tiff file '...' failed in VSI_TIFFOpen().
After further investigation, I realized it is caused by a platform-dependent string parsing in nbar.py (the following line).
filename = img_path.split("/")[-1].replace("jp2", "tif")
I would suggest a quick fix like this:
The text was updated successfully, but these errors were encountered: