Hello Sen4CAP Team,
I open this ticket to ask you questions regarding the L4A product and especially the crop type. In fact, I am a beginner but I would like to get the result L4A Crop Type. I couldn’t find the information to do so. Indeed, the following documentation: http://esa-sen4cap.org/sites/default/files/02_Sen4CAP_TrainingforBeginners_SystemOperation.pdf doesn’t allow me to understand how to properly write the documents that have to be imported.
Regarding my parcels, I uploaded the following shapefile:
Then my main problem was the LUT file (LUT for France?). I haven’t been able to find any guidance on how it should be written in the forum/documentation, where can I find the information to properly build the necessary files please?
http://esa-sen4cap.org/content/data: examples of crop code LUT and other config files and tables to upload in the system to be able to run the advanced processors (L4x)
For you parcels dataset it looks good. So in the LUT, in the Ori_crop column, you have to list all the possible values of the CODE_CULTU field (I guess that it is the attribute field that is used to define the crop type), then you have to define the information corresponding to each of these values. Among these information, CTnumL4A (and the corresponding name CTL4A) is the crop code on which the classification is performed -> it enables you to group some original crop codes in broader classes for the classification if you would like to, or you can just define one numeric value for each original crop code.
Thanks for your very interesting response it helps me a lot. I was able to correctly add my files to my extent. However, I still haven’t managed to achieve the desired result.
You can click on [Copy to clipboard] from the S4CCropType step which shows an error above and paste it in a notepad to potentially check the problem. If you prefer you can paste it here for me to check.
One problem could be that there are not enough preprocessed data, because I see that there are no S1 backscattering and oherence products available (except if you tried to run a classification with S2 markers only, in this case it does not matter).
Thanks for your time. Indeed, I tried using a classification with S2 markers only.
The error I got is the following:
Traceback (most recent call last):
File “/usr/bin/crop-type-wrapper.py”, line 346, in
main()
File “/usr/bin/crop-type-wrapper.py”, line 198, in main
lpis_path = get_lpis_path(conn, config.site_id, config.season_end)
File “/usr/bin/crop-type-wrapper.py”, line 92, in get_lpis_path
return results[0][0]
IndexError: list index out of range
From what I see in the last logs, the error is that the LPIS cannot be found. This might be due to 2 reasons:
Either your initial LPIS files and LUT were not succesfully imported in the system (an error maybe occurred during import). To check if you have a valid LPIS product imported you can do :
psql -U admin sen4cap -c “select * from product where product_type_id = 14”
If you get a valid line, this means that your LPIS was successfully imported. In this case, you should check the second point.
2. If you have a valid LPIS product, please check that this product is in a directory ending with /2020, as from what I see, you have the season for 2020. If it ends with another year, you must upload again the LPIS and LUT but switching first to year 2020 (by default, the current year is selected in the “Upload” page)