Provides concrete implementations of environment–wide operations (envops).
Provides concrete functionality for environment–wide operations (envops) related to statistical techniques using l1l2py library.
Bases: kdvs.fw.EnvOp.EnvOp
The parametrizable pre–EnvOp (i.e. that will be executed before all computational jobs from statistical techniques for current category) that generates splits from given labels vector, and places the result directly into specific placeholder variable that the statistical technique exposes. This way, any interested statistical technique may share exactly the same split. This approach is used in L1L2_L1L2 and L1L2_RLS techniques so that they can share one uniform external split. To use it, the instance of this class must be configured with the following parameters:
- ‘enclosingCategorizerID’ – the identifier of the Categorizer on the level this EnvOp will be called
- ‘extSplitParamName’ – name of the parameter that holds the number of splits to be made (‘the counter’)
- ‘extSplitPlaceholderParam’ – name of the parameter in statistical technique that will hold the generated split
For instance, if ‘extSplitPlaceholderParam’ equals to ‘splits’, then such parameter must be present during configuration of statistical technique, with initial value None, in configuration file:
- techConf1 = {..., ‘splits’ : None, ...}
This EnvOp works assuming the following conditions are met:
- in all statistical techniques that expose placeholder parameter, the ‘counter’ value is exactly the same
- in all categories on current hierarchy level, all data subsets have the same single statistical technique assigned for processing (so we obtain single ‘counter’ value),
- there is at least one valid categorizer BELOW the enclosing one with at least one technique that exposes placeholder parameter.
If any of those conditions is NOT met, an Error is raised.
Parameters : | kwargs : dict
|
---|---|
Raises : | Error :
|
Perform generation of splits and put them into all statistical techniques that expose certain placeholder parameter. Refer to the comments for the detailed procedure.
Parameters : | env : ExecutionEnvironment
|
---|---|
Raises : | Error :
Error :
|