Metalearners

Latest version: v0.11.0

Safety actively analyzes 685525 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 3

0.11.0

-------------------

**New features**

* Add support for using ``scipy.sparse.csr_matrix`` as datastructure for covariates ``X``.

0.10.0

-------------------

**New features**

* Add abstract method
:meth:`~metalearners.metalearner.MetaLearner.predict_conditional_average_outcomes`
to :class:`~metalearners.metalearner.MetaLearner`.

* Implement
:meth:`~metalearners.rlearner.RLearner.predict_conditional_average_outcomes`
for :class:`~metalearners.rlearner.RLearner`.

**Bug fixes**

* Fix bug in which the :class:`~metalearners.slearner.SLearner`'s
inference step would have some leakage in the in-sample scenario.

0.9.0

------------------

**New features**

* Add :meth:`metalearners.metalearner.MetaLearner.init_args`.

* Add :class:`metalearners.utils.FixedBinaryPropensity`.

* Add ``_build_onnx`` to :class:`metalearners.MetaLearner` abstract class and implement it
for :class:`metalearners.TLearner`, :class:`metalearners.XLearner`, :class:`metalearners.RLearner`
and :class:`metalearners.DRLearner`.

* Add ``_necessary_onnx_models`` to :class:`metalearners.MetaLearner`.

* Add :meth:`metalearners.metalearner.DRLearner.average_treatment_effect` to
compute the AIPW point estimate and standard error for
_average treatment effects (ATE)_ without requiring a full model fit.

0.8.0

------------------

**New features**

* Add :meth:`metalearners.metalearner.MetaLearner.fit_all_nuisance` and
:meth:`metalearners.metalearner.MetaLearner.fit_all_treatment`.

* Add optional ``store_raw_results`` and ``store_results`` parameters to :class:`metalearners.grid_search.MetaLearnerGridSearch`.

* Renamed :class:`metalearners.grid_search._GSResult` to :class:`metalearners.grid_search.GSResult`.

* Added ``grid_size_`` attribute to :class:`metalearners.grid_search.MetaLearnerGridSearch`.

* Implement :meth:`metalearners.cross_fit_estimator.CrossFitEstimator.score`.

**Bug fixes**

* Fixed a bug in :meth:`metalearners.metalearner.MetaLearner.evaluate` where it failed
in the case of ``feature_set`` being different from ``None``.

0.7.0

------------------

**New features**

* Add optional ``adaptive_clipping`` parameter to :class:`metalearners.DRLearner`.

**Other changes**

* Change the index columns order in ``MetaLearnerGridSearch.results_``.

* Raise a custom error if only one class is present in a classification outcome.

* Raise a custom error if there are some treatment variants which have seen classification outcomes which have not appeared for some other treatment variant.

0.6.0

------------------

**New features**

* Implement :class:`metalearners.grid_search.MetaLearnerGridSearch`.

* Add a ``scoring`` parameter to :meth:`metalearners.metalearner.MetaLearner.evaluate` and
implement the abstract method for the :class:`metalearners.XLearner` and
:class:`metalearners.DRLearner`.

**Other changes**

* Increase lower bound on ``scikit-learn`` from 1.3 to 1.4.

* Drop the run dependency on ``git_root``.

Page 1 of 3

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.