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
Seviri L1b native Solar zenith angle #1510
Comments
Hi @cherif2019-dev, for this you need to also use the
This will give you the solar zenith angle for each pixel as a numpy array,
|
Thank you so much Simon,
Please how can I print the zenith angle for a specific lat long
Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10
From: Simon Proud<mailto:notifications@github.com>
Sent: Tuesday, January 19, 2021 1:05 PM
To: pytroll/satpy<mailto:satpy@noreply.github.com>
Cc: cherif2019-dev<mailto:charfi008@hotmail.fr>; Mention<mailto:mention@noreply.github.com>
Subject: Re: [pytroll/satpy] Seviri L1b native Solar zenith angle (#1510)
Hi @cherif2019-dev<https://github.com/cherif2019-dev>, for this you need to also use the pyorbital library.
Here's an example script, please note you'll have to adapt the filenames:
from satpy import Scene
from pyorbital import astronomy
# Choose composite
compo = 'natural_color'
# Create scene and load composite
scn = Scene([my_input_nat_file', reader='seviri_l1b_native')
scn.load([compo], upper_right_corner='NE')
# Extract longitudes and latitudes from scene area
lons, lats = scn[compo].attrs['area'].get_lonlats()
sza = astronomy.sun_zenith_angle(scn.start_time, lons, lats)
This will give you the solar zenith angle for each pixel as a numpy array, sza.
You can save the results with:
import numpy as np
import gdal
scn.save_dataset('natural_color', filename=my_rgb_filename, fill_value=0)
rows, cols = sza.shape
ds = gdal.GetDriverByName('GTiff').Create(my_sza_filename, cols, rows, 1, gdal.GDT_Float32)
ds.GetRasterBand(1).WriteArray(sza)
ds = None
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#1510 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ANUYAREVMPXRDXLYLLZ6AKDS2VDO7ANCNFSM4WIM6UFA>.
|
You can use the |
Great, thank you very much
Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10
From: Martin Raspaud<mailto:notifications@github.com>
Sent: Tuesday, January 19, 2021 8:42 PM
To: pytroll/satpy<mailto:satpy@noreply.github.com>
Cc: cherif2019-dev<mailto:charfi008@hotmail.fr>; Mention<mailto:mention@noreply.github.com>
Subject: Re: [pytroll/satpy] Seviri L1b native Solar zenith angle (#1510)
You can use the astronomy.sun_zenith_angle function as @simonrp84<https://github.com/simonrp84> showed.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#1510 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ANUYARGC2L3ASGOD2D4XFXDS2WZADANCNFSM4WIM6UFA>.
|
Thanks @simonrp84 for the nice code snippet! I'll close this issue, @cherif2019-dev feel free to reopen it or add comments if you have further questions. |
Hi Andrea,
Hope you are doing well,
I am working on Eumetsat MSG4 data coming from a receiving station, when I tried to use the same data coming from the API(nat file), I found a difference between the two data,
Have you an idea from where this difference comes and what is the most reliable source.
Thank you.
Best Regards,
Cherif
Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10
From: Andrea Meraner<mailto:notifications@github.com>
Sent: Friday, January 22, 2021 1:31 PM
To: pytroll/satpy<mailto:satpy@noreply.github.com>
Cc: cherif2019-dev<mailto:charfi008@hotmail.fr>; Mention<mailto:mention@noreply.github.com>
Subject: Re: [pytroll/satpy] Seviri L1b native Solar zenith angle (#1510)
Thanks @simonrp84<https://github.com/simonrp84> for the nice code snippet! I'll close this issue, @cherif2019-dev<https://github.com/cherif2019-dev> feel free to reopen it or add comments if you have further questions.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#1510 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ANUYARAMU6TAOLI2CRDUYN3S3FAVTANCNFSM4WIM6UFA>.
|
Hi @cherif2019-dev, could you please elaborate on what differences you see? In theory there shouldn't be any. |
Yes Andrea, please find attached 2 plots: the upper is the T04 plot from the seviri API, the second is the difference between T04 taken by the receiving station(RS) and by api :API-RS
Thank you.
Sent from Mail<https://go.microsoft.com/fwlink/?LinkId=550986> for Windows 10
From: Andrea Meraner<mailto:notifications@github.com>
Sent: Monday, February 1, 2021 9:09 PM
To: pytroll/satpy<mailto:satpy@noreply.github.com>
Cc: cherif2019-dev<mailto:charfi008@hotmail.fr>; Mention<mailto:mention@noreply.github.com>
Subject: Re: [pytroll/satpy] Seviri L1b native Solar zenith angle (#1510)
Hi @cherif2019-dev<https://github.com/cherif2019-dev>, could you please elaborate on what differences you see? In theory there shouldn't be any.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub<#1510 (comment)>, or unsubscribe<https://github.com/notifications/unsubscribe-auth/ANUYAREZHR7SFQPT7IUWFTDS43N6FANCNFSM4WIM6UFA>.
|
@cherif2019-dev I'm afraid the attachments to the email are not included in the issue reply and are now lost. Could you please post the images as an answer to the issue via the Github webpage? |
Please, how to get the solar zenith angle fom the Eumetsat seviri L1b native scene.
The text was updated successfully, but these errors were encountered: