mlpack / mlpack

mlpack: a fast, header-only C++ machine learning library

Home Page:https://www.mlpack.org/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Fatal error occurred when calling mlpack.bayesian_linear_regression()

tunglinwood opened this issue · comments

Problem location

https://www.mlpack.org/doc/stable/python_documentation.html#bayesian_linear_regression

Description of problem

When I am trying out mlpack under Python bindings from examples of Airbnb_Price_Prediction_Regression_py.ipynb, there is issue with 4.3 Linear Regression, in which mlpack.linear_regression has error, saying the module is not callable.

So I check the documentation of mlpack-4.3.0, finding out that linear_regression module is no more available. And I try to replace the module for bayesian_linear_regression, and it returns “ fatal error; see Log::Fatal output.” Does this mean that there is something wrong with Armadillo or other causes?

(Update)
Just found there is another section, 4.5 Bayesian Linear Regression, to demonstrate Bayesian Linear Regression, in which the argument input should be changed into input_ to yield outcome without any errors detected.

My other question is that should we remove Section 4.3 Linear Regression and 4.4 Ridge Regression? Or there is other way to modify the source code with a PR?

Hi @tunglinwood,
It looks like the issue comes from the changes in the bindings for the mlpack models, not from an issue within the mlpack library itself.

I've submitted a PR that should resolve the errors you encountered in sections 4.3 and 4.5 of the notebook, (as well as one I found in 4.4 and in 3.2, Bivariate Analysis).

Please take a look at the PR, and let me know if it clears things up for you :)