-
Notifications
You must be signed in to change notification settings - Fork 12
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
GEDI L2A no effect of degrade flags #446
Comments
@ayush12gupta I see in your notebook you're setting degrade_flag=70. As far as I know it is a boolean value see this discussion https://github.com/orgs/SlideRuleEarth/discussions/442 But in short, degrade_flag=0=False -> "not degraded" , degrade_flag=1=True -> "degraded quality" |
@scottyhq Thanks for clarifying that, so when degrade filtering is used it is removing all non zero degrade flag values right ? However I am still wondering why the total no. of GEDI points are the same with and without degrade filter. And why there is difference in the total no. of GEDI points when read using raw files vs what sliderule returns. |
Yes, all degrade=1 values in theory. Maybe there is a bug though. In order to reproduce your examples, we'd need your polygon (/home/ayushg12/Desktop/UW_study/notebook/shapefiles/mt_baker_area.shp). So you can either print it out as text if it's simple, or just commit it to github (preferably as GeoJSON)! |
Ok got it! For reproducing the bug here is the mt_baker_area shapefile in GeoJSON attached. |
Thanks @ayush12gupta for this example. The last 3 cells are telling. Yes, this is potentially a bug. We should revisit GEDI flags and how we're handling these on the server vs. client side. Perhaps allowing users more granularity to specify filters if desired. Definitely need to improve the doc around these topics.
|
Hmm. Not sure I understand. This is a text file, and Github should support natively (with preview). For example: https://github.com/johan/world.geo.json/blob/master/countries.geo.json For simple polygons (like a square bbox), you can also just copy and paste the geojson text into a notebook cell (or github issue thread) |
Got it!, GitHub was not supporting the .geojson extension. I changed it and updated the previous comment. |
Thanks @ayush12gupta I spoke too soon about my interpretation of degrade_flag. From sliderule's point of view degrade_flag=1 -> "degraded" for any reason, which according to LPDAAC Data Dictionary can be due to many things. Looks like these flag parameters were all updated recently in v4.8.0: sliderule/docs/rtd/source/release_notes/release-v4-8-0.md Lines 37 to 42 in f8e233d
So I suggest changing your code to the following: # Note: .geojson instead of .geo.json :)
aoi = gpd.read_file('mt_baker_area.geojson')
params ={
"poly":sliderule.toregion(aoi)['poly'],
"degrade_filter": True, # no degraded samples, 2547 points in aoi -> 232 points
}
gf = gedi.gedi02ap(params, resources=granules) |
Ok got it, just need to change the flag parameters. Thanks! |
When using
gedi.gedi02ap
it has no effect when changing degrade flags. I also tried comparing the no. of GEDI points when read using the raw file and what sliderule returns, there is a difference in ones from sliderule and raw file with both degrade flag and without it. I have shown this issue in the notebook shared below.https://notebooksharing.space/view/5b8da8ac5595d8d982df18174dc21b347ce23b2fb8d2659e0581a57f0d0b2cf0#displayOptions=
mt_baker_area.zip
The text was updated successfully, but these errors were encountered: