Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How do we include python documentation in doc-strings? #37

Open
ablaom opened this issue Mar 3, 2022 · 0 comments
Open

How do we include python documentation in doc-strings? #37

ablaom opened this issue Mar 3, 2022 · 0 comments

Comments

@ablaom
Copy link
Member

ablaom commented Mar 3, 2022

Once you import a python model using Sckitlearn.jl the documentation is available:

julia> @sk_import linear_model: Lasso
PyObject <class 'sklearn.linear_model._coordinate_descent.Lasso'>

help?> Lasso
search: Lasso LassoRegressor LassoCVRegressor LassoLarsRegressor LassoLarsICRegressor LassoLarsCVRegressor

Linear Model trained with L1 prior as regularizer (aka the Lasso)

    The optimization objective for Lasso is::

        (1 / (2 * n_samples)) * ||y - Xw||^2_2 + alpha * ||w||_1

...

However, we do not want using MLJScikitLearnInterface to generate every python model to get this documentation, for inclusion in MLJ model docstrings. (Currently, the python objects are only generated at run time, when someone calls fit on the MLJ model; see here). So I guess we generate this documentation separately and have __init__ load it in? Then there is the problem of synchronisation. Can julia artefacts help here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant