geemap icon indicating copy to clipboard operation
geemap copied to clipboard

Support for MULTIPROBABILITY outputs with RF classifiers

Open KMarkert opened this issue 3 years ago • 0 comments

Description

There has been current discussion on implementing PROBABILITY output modes with the locally trained RF models (#522 ). The recent PR to support this request (#550) only works for binary classification problems.

Per the discussion on this string: https://issuetracker.google.com/issues/192387018, MULTIPROBABILITY outputs can be achieved by outputting the probability that the prediction class is correct. We would then need to keep track of which class has which probability from trees and reduce.

Source code

There is a start to the feature here: https://github.com/giswqs/geemap/blob/master/geemap/ml.py#L81

But this extracts the probabilities for each class (i.e. a n length vector of probabilities) which does not work with ee.Classifier.decisionTree. We would need to refactor to output only one probability and keep track of which class that probability is for so that it can be reshaped later.

I expect the part of keeping track of probability values and which class it belongs to will require a custom wrapper around ee.Classifier.decisionTree.

KMarkert avatar Jul 01 '21 20:07 KMarkert