cstjean / ScikitLearn.jl

Julia implementation of the scikit-learn API https://cstjean.github.io/ScikitLearn.jl/dev/
Other
547 stars 75 forks source link

Force installation of `scikit-learn` v0.23 #99

Closed giordano closed 3 years ago

cstjean commented 3 years ago

🎉 Awesome!

Notebook examples: Error During Test at /Users/travis/build/cstjean/ScikitLearn.jl/test/runtests.jl:63
  Got exception outside of a @test
  LoadError: PyError ($(Expr(:escape, :(ccall(#= /Users/travis/.julia/packages/PyCall/BD546/src/pyfncall.jl:43 =# @pysym(:PyObject_Call), PyPtr, (PyPtr, PyPtr, PyPtr), o, pyargsptr, kw))))) <class 'AttributeError'>
  AttributeError("'str' object has no attribute 'decode'")
    File "/Users/travis/.julia/conda/3/lib/python3.8/site-packages/sklearn/linear_model/_logistic.py", line 1407, in fit
      fold_coefs_ = Parallel(n_jobs=self.n_jobs, verbose=self.verbose,
    File "/Users/travis/.julia/conda/3/lib/python3.8/site-packages/joblib/parallel.py", line 1041, in __call__

Not sure where/how old this error is. I wonder if maybe we should look into even older versions than v0.23...

giordano commented 3 years ago

Interestingly enough, it doesn't error for me locally :confused:

giordano commented 3 years ago

The last successful job on Travis used v0.23.1, here we're using v0.23.2. But as I said above, it works for me locally with v0.23.2, so I wonder whether the issue is some of the other conda packages.

cstjean commented 3 years ago

Interestingly enough, it doesn't error for me locally 😕

Did you start from a virgin conda, or did you already have some packages installed?

giordano commented 3 years ago

Great question: I was testing in my standard depot where I have other packages in the conda environment. I just tried a clean Julia depot, so also completely clean conda environment and it fails also for me there. Time to figure out what's the offending package...

giordano commented 3 years ago

Frankly, I'm running out of ideas. The notebook itself works for me, I have little clue what's going on here. I'm moderately sure all changes I made to the notebook are unnecessary to make it work. And in #98 tests pass even with scikit-learn v0.24

cstjean commented 3 years ago

And in #98 tests pass even with scikit-learn v0.24

Yeah, that's pretty amazing. But then, I guess we shouldn't merge this, right? Is there a point in forcing a particular version if the latest version works?

giordano commented 3 years ago

At this point I'm very confused as well. I was going by your comment in https://github.com/cstjean/ScikitLearn.jl/pull/96#issuecomment-825273831 and thought you were more sure that this package was incompatible with scikit-learn 0.24, but at this point it looks to me there is some mess with python packages we don't really understand (and probably have very little room to control)

cstjean commented 3 years ago

and probably have very little room to control

I guess we can specify the version of everything that's problematic, but yeah, sounds like a painful rabbit hole to get into.

giordano commented 3 years ago

I'm closing this pull request as it doesn't seem to solve any issues, but at least now we know how to install a specific version of a Conda package, if necessary