utils_sh#
- eocrops.inputs.utils_sh.config_sentinelhub_cred(api, client_id, client_secret)[source]#
Configure properly Sentinelhub credential fetching information from the configuration tool python class. :return: SHConfig
- eocrops.inputs.utils_sh.calculate_valid_data_mask(eopatch)[source]#
Define which pixel will be masked from eo-patch Inputs :
eopatch : patch downloaded from eo-learn packages (eopatch object with arrays)
- eocrops.inputs.utils_sh.calculate_coverage(array)[source]#
Share of pixels not contaminated by clouds Inputs :
array : array from an eopatch object that contains information about cloud coverage (e.g Sentinel-2 L1C)
- class eocrops.inputs.utils_sh.AddValidDataCoverage(*args, **kwargs)[source]#
Bases:
EOTaskShare of pixels not contaminated by clouds Inputs :
EOTask : workflow as EOTask object
Stores initialization parameters and the order to the instance attribute init_args.
- Parameters:
args (Any) –
kwargs (Any) –
- Return type:
Self
- class eocrops.inputs.utils_sh.AddValidDataMaskTask(*args, **kwargs)[source]#
Bases:
EOTaskStores initialization parameters and the order to the instance attribute init_args.
- Parameters:
args (Any) –
kwargs (Any) –
- Return type:
Self
- class eocrops.inputs.utils_sh.ValidDataS2(*args, **kwargs)[source]#
Bases:
EOTaskThe tasks recognize clouds from Sentinel Scene Layers (SCL) obtained from Sen2Corr
Stores initialization parameters and the order to the instance attribute init_args.
- Parameters:
args (Any) –
kwargs (Any) –
- Return type:
Self
- class eocrops.inputs.utils_sh.ValidDataVHRS(*args, **kwargs)[source]#
Bases:
EOTaskThe tasks recognize clouds from Sentinel Scene Layers (SCL) obtained from Sen2Corr
Stores initialization parameters and the order to the instance attribute init_args.
- Parameters:
args (Any) –
kwargs (Any) –
- Return type:
Self
- class eocrops.inputs.utils_sh.CountValid(*args, **kwargs)[source]#
Bases:
EOTaskThe task counts number of valid observations in time-series and stores the results in the timeless mask.
Stores initialization parameters and the order to the instance attribute init_args.
- class eocrops.inputs.utils_sh.ValidDataCoveragePredicate(threshold)[source]#
Bases:
objectKeep an image only if below % of non contaminated pixels Inputs :
threshold (float) : upper bound of percentage of pixel predicted as cloudy
- class eocrops.inputs.utils_sh.EmptyTask(*args, **kwargs)[source]#
Bases:
EOTaskThis task does not make any change. It is just to avoid to duplicate the LinearWorflow with if/else For example, saving a EOPatch in the workflow would depend if the user specify a path in the parameters of the function workflow
Stores initialization parameters and the order to the instance attribute init_args.