Hello @marpet and everyone!
I am using the HDA API from Wekeo to access Sentinel-2 and -3 data and I wanted to know if there is a way to read the product without writing it on the disk. Right now, I’m using ZipFile, but I don’t know how to parse it to the ProductIO reader.
Example code with url and headers retrieved from the HDA API to access an OLCI L1B product :
from snappy import ProductIO
from zipfile import ZipFile
from io import BytesIO
response = requests.get(url, headers=headers)
zipfile = ZipFile(BytesIO(response.content))
xmlname = [zf for zf in zipfile.namelist() if (‘xml’ in zf and ‘S3’ in zf)]
product = ProductIO.readProduct(zipfile.read(xmlname))
My code is maybe a bit stupid as I provide only the content of the xml file but maybe you have a solution. Right now, I just write the file on the disk but it would be great to skip this step!
Thanks in advance for your reply!