factor_agent.config.AcceptanceConfig#
- class AcceptanceConfig(model, seeds=(0, 1, 2), val_size=0.2, top_k=100, contribution='none', factor_root=None, package='factor_agent.accepted', export_start=None, export_end=None)[source]#
Bases:
objectHow
Acceptancevalidates, opens the hold-out and exports.modelis the acceptance model, a template (factor_agent._acceptance_model): the component config of a quantlabBaseModelorModelEnsemble, whose own factors are the baseline (empty: the reference set). Every baseline feature, and each accepted factor’s scored values, is read as the campaign’sscoringreads.- Raises:
- ValueError
If there is no seed,
modelis aSeedEnsemble, orcontributionis not one ofCONTRIBUTIONS.- TypeError
If
modelis not a model’s component config.
Methods#
Read the |
Attributes#
- AcceptanceConfig.contribution = 'none'#
Each accepted factor’s contribution in validation: none, drop_one, add_one or both; never on the hold-out.
- AcceptanceConfig.export_end = None#
Last date of an exported store; None: the hold-out’s end, else the validation’s.
- AcceptanceConfig.export_start = None#
First date of an exported store; None: the training segment’s start.
- AcceptanceConfig.factor_root = None#
Where exported stores go,
<factor_root>/<name>/; an export needs it.
- AcceptanceConfig.package = 'factor_agent.accepted'#
The package the exported
FactorKunQuantsubclasses are written into, one module each.
- AcceptanceConfig.seeds = (0, 1, 2)#
The seeds every model is trained with; each replaces every member’s
random_seed.
- AcceptanceConfig.top_k = 100#
Members held by the plain TopK book.
- AcceptanceConfig.val_size = 0.2#
Share of the training window each model validates (early-stops) on, at its end.
- AcceptanceConfig.model#
The acceptance model’s template; required, so no campaign is accepted against a default model.