CNES / MAJA

Level-2A processor used for atmospheric correction and cloud-detection. The active repository is the one below, this one is kept to leave access to the older issues.
https://gitlab.orfeo-toolbox.org/maja/maja
Apache License 2.0
139 stars 25 forks source link

SWBD not available on T29SNA Tile ID #29

Closed EkicierNico closed 4 years ago

EkicierNico commented 5 years ago

Hello, I have a new issue on tile T29SNA concerning SWBD data. According to logs of Maja, we need these tiles : ['w010n36', 'w010n37', 'w009n36', 'w009n37', 'w008n36', 'w008n37']

When I go to EarthExplorer and put the shapefile of T29SNA tile, the query returns only these SWBD tiles : 'w009n36', 'w009n37', 'w008n36', 'w008n37'

Furthermore, it seems that 'w010n36' 'w010n37' does not exist...

If you need more informations, don't hesitate. Thanks a lot.

Nicolas

olivierhagolle commented 5 years ago

Hi Nicolas, the SWBD authors did something bad (in my opinion) : when a tile is only water or only land, it is not provided. DTMCreation handles that. We create a new vector which is fully land or fully water, using an external dataset which tells us which is most probable. So, even if you do not find the SWBD data, it should work. Olivier

EkicierNico commented 5 years ago

Hi Olivier, Thanks for your answer.

Actually, it does not work, I tested on 19HCC Tile at Chile and we need w070s34 SWBD tile. Here is the error from MAJA :

missing SWBD watr file :  w070s34
Traceback (most recent call last):
  File "/Start-MAJA/prepare_dtm/DTMCreation.py", line 334, in <module>
    creator.run(args.out, args.tempout)
  File "/Start-MAJA/prepare_dtm/DTMCreation.py", line 294, in run
    water_zipped = self.WaterZipped)
  File "/Start-MAJA/prepare_dtm/../prepare_dtm/tuilage_mnt_eau_S2.py", line 203, in run
    calcul_masque_eau_mnt, working_dir=working_dir)
  File "/Start-MAJA/prepare_dtm/../prepare_dtm/lib_mnt.py", line 531, in fusion_mnt
    land = TestLand(liste_centre_eau[i][0], liste_centre_eau[i][1])
  File "/Start-MAJA/prepare_dtm/../prepare_dtm/lib_mnt.py", line 57, in TestLand
    layer = dataSource.GetLayer()
AttributeError: 'NoneType' object has no attribute 'GetLayer'

Same error on 30QVD tile with w004n17 SWBD tile.

Do you have an idea ? Thank you Nicolas

olivierhagolle commented 5 years ago

I think I have done something bad, which is assuming you start DTM_creation from the folder that contains the DTMCreation file... That's why the file which tells if we are over a continent or an ocean is not found. I will correct that ASAP...