Commit ac8f7aba authored by ArthurVincent's avatar ArthurVincent
Browse files

ENH: add, at the begining of the chain, a verification. and sort list of...

ENH: add, at the begining of the chain, a verification. and sort list of classifications and their confidence map (nodata.py)
parent 83323f21
......@@ -51,7 +51,7 @@ argClassification:
fusionOptions :'-undecidedlabel 0 -nodatalabel 0 -method majorityvoting'
pixType : 'uint8'
confusionModel : False #True or False
noLabelManagement : 'maxConfidence'#MaxConfidence or learningPriority
noLabelManagement : 'MaxConfidence'#MaxConfidence or learningPriority
}
################################################################################################
......
......@@ -343,6 +343,13 @@ def launchChain(Fileconfig, reallyLaunch=True):
f = file(Fileconfig)
cfg = Config(f)
chainType = cfg.chain.executionMode
MODE = cfg.chain.mode
classifier = cfg.argTrain.classifier
classificationMode = cfg.argClassification.classifMode
if (MODE=="multi_regions" and classificationMode=="fusion" and classifier!="rf") and (MODE=="multi_regions" and classificationMode=="fusion" and classifier!="svm"):
raise ValueError('If you chose the multi_regions mode, you must use rf or svm classifier')
if chainType == "parallel":
genJobs(Fileconfig)
pathChain = gen_oso_parallel(Fileconfig)
......
......@@ -179,6 +179,8 @@ def noData(pathTest,pathFusion,fieldRegion,pathToImg,pathToRegion,N,pathConf,pat
for seed in range(N):
imgConfidence=fu.FileSearch_AND(pathTest+"/classif",True,"confidence_seed_"+str(seed)+".tif",currentTile)
imgClassif=fu.FileSearch_AND(pathTest+"/classif",True,"Classif_"+currentTile,"seed_"+str(seed))
imgConfidence.sort()
imgClassif.sort()
exp,il = buildConfidenceExp(pathFusion,imgConfidence,imgClassif)
imgData = pathDirectory+"/"+currentTile+"_FUSION_NODATA_seed"+str(seed)+".tif"
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment