Sen2Agri / Sen2Agri-System

Sentinel-2 for Agriculture (Sen2Agri) is a software system processing high resolution satellite images for agricultural purposes funded by ESA (European Space Agency). Please register on the Sen2Agri webpage for Sen2Agri system updates and information.
http://www.esa-sen2agri.org
Other
115 stars 38 forks source link

missing import of log in dem.py #22

Closed valpesendorfer closed 5 years ago

valpesendorfer commented 5 years ago

There seems to be a missing import of log from sen2agri_common_db in dem.py of Sen2Agri v2.0.

Doesn't seem to be an issue if everything is ok with the input, but will fail if condition in line number 173 is True.

lnicola commented 5 years ago

Thank you, and sorry for the late reply. Fixed in a future version:

diff --git a/sen2agri-processors/DEM-WB/test/dem.py b/sen2agri-processors/DEM-WB/test/dem.py
index 5e991d72..ed331085 100755
--- a/sen2agri-processors/DEM-WB/test/dem.py
+++ b/sen2agri-processors/DEM-WB/test/dem.py
@@ -30,7 +30,7 @@ from os.path import isdir, join
 import sys
 from signal import signal, SIGINT, SIG_IGN
 from multiprocessing import Pool, TimeoutError
-from sen2agri_common_db import GetExtent, ReprojectCoords, create_recursive_dirs, run_command
+from sen2agri_common_db import GetExtent, ReprojectCoords, create_recursive_dirs, log, run_command

 def resample_dataset(src_file_name, dst_file_name, dst_spacing_x, dst_spacing_y):