[processing/otb]Add specific rule to load ComputeOGRLayersFeaturesStatistics

This commit is contained in:
Alexia Mondot 2015-07-02 12:19:05 +02:00 committed by volaya
parent c548f8d8a4
commit 5e9647d3ff

View File

@ -329,6 +329,23 @@ def adaptComputePolylineFeatureFromImage(commands_list):
return commands_list2
def adaptComputeOGRLayersFeaturesStatistics(commands_list):
"""
Remove parameter and user value instead of giving None.
Check geoid file, srtm folder and given elevation and manage arguments.
"""
commands_list2 = commands_list
adaptGeoidSrtm(commands_list2)
for item in commands_list:
if "None" in item:
index = commands_list2.index(item)
argumentToRemove = commands_list2[index - 1]
commands_list2.remove(item)
commands_list2.remove(argumentToRemove)
# commands_list2.append(item)
return commands_list2
def ckeckGeoidSrtmSettings():
folder = ProcessingConfig.getSetting(OTBUtils.OTB_SRTM_FOLDER)
if folder is None: