stanfordmlgroup / ngboost

Natural Gradient Boosting for Probabilistic Prediction
Apache License 2.0
1.66k stars 219 forks source link

Add negative binomial distribution #356

Open ashler-herrick opened 2 months ago

ashler-herrick commented 2 months ago

Added the negative binomial distribution by following the guide here: https://stanfordmlgroup.github.io/ngboost/5-dev.html

ashler-herrick commented 2 months ago

@alejandroschuler Any tips on how to fix the github actions failing?

alejandroschuler commented 2 months ago

@ryan-wolbeck can probably help!

ryan-wolbeck commented 2 months ago

@ashler-herrick you will need to install Make in your development environment then run 'make lint' that will fix the formatting error you are seeing.

ashler-herrick commented 2 months ago

@ryan-wolbeck Any ideas on how to fix the failing tests? I've fixed the formatting errors, ran 'make test' locally (passed) but it seems to be failing for Python 3.9 through GH Actions

ryan-wolbeck commented 1 month ago

@ashler-herrick it's probably failing only in the github action tests because your local environment is probably not 3.9. I would try creating a new conda env and setting it to 3.9 then do 'make' to install and re-run the tests. I'll pull the code here and take a look and get back to you with what I see.

ryan-wolbeck commented 1 month ago

Interesting, when I run on 3.9 locally don't get the failure, this will take me more time to dig into. Going to also re-run the github actions to see if it's repeating

ryan-wolbeck commented 1 month ago

@ashler-herrick now when I re-run the actions I get the following linting error

***** Module ngboost.api ngboost/api.py:57:4: R0917: Too many positional arguments (15/5) (too-many-positional-arguments) ngboost/api.py:143:4: R0917: Too many positional arguments (13/5) (too-many-positional-arguments) ngboost/api.py:235:4: R0917: Too many positional arguments (13/5) (too-many-positional-arguments) ngboost/api.py:293:4: R0917: Too many positional arguments (7/5) (too-many-positional-arguments)


Your code has been rated at 9.86/10

***** Module ngboost.ngboost ngboost/ngboost.py:53:4: R0917: Too many positional arguments (15/5) (too-many-positional-arguments) ngboost/ngboost.py:175:4: R0917: Too many positional arguments (6/5) (too-many-positional-arguments) ngboost/ngboost.py:204:4: R0917: Too many positional arguments (10/5) (too-many-positional-arguments) ngboost/ngboost.py:262:4: R0917: Too many positional arguments (10/5) (too-many-positional-arguments)