ecopy icon indicating copy to clipboard operation
ecopy copied to clipboard

ModuleNotFoundError ecopy.regression.isoFunc

Open DDeFilippis opened this issue 3 years ago • 4 comments

`ModuleNotFoundError Traceback (most recent call last) in ----> 1 import ecopy

~/Downloads/ecopy-master/ecopy/init.py in 2 3 ----> 4 from .regression import * 5 from .ordination import * 6 from .diversity import *

~/Downloads/ecopy-master/ecopy/regression/init.py in 1 from .nls import nls ----> 2 from .isoregress import isotonic

~/Downloads/ecopy-master/ecopy/regression/isoregress.py in 2 from pandas import DataFrame, Series 3 import matplotlib.pyplot as plt ----> 4 from .isoFunc import _isotonic_regression 5 6 class isotonic:

ModuleNotFoundError: No module named 'ecopy.regression.isoFunc'`

Death by dependency. Given that it is the only module with a single C function maybe we could work on rewriting it in pure python to save the headache of having to deal with installing Cython too.

DDeFilippis avatar Jul 30 '20 21:07 DDeFilippis

I wrote a pure python implementation first, but it was deathly slow compared to C. If you can write a pure python one that's fast, go for it. But I'm guessing the SciKit folks tried that.

Auerilas avatar Jul 30 '20 21:07 Auerilas

Any ideas as to why this error is manifesting? I'm using Python 3.7.3 and Cython 0.29.21 but it seems like the module not found error is because cython isn't compiling the module.

DDeFilippis avatar Jul 30 '20 21:07 DDeFilippis

scikit-learn has had an isotonic regression since0.18 I think. https://scikit-learn.org/stable/modules/isotonic.html I'm hoping that I can get this running on my machine so that I can point other ecologists to it, since it seems less daunting than scikit-learn.

DDeFilippis avatar Jul 30 '20 21:07 DDeFilippis

Yea. I used their isotonic function. And part of the point of EcoPy was that scikit is confusing, especially for ordination. I never could make sense of their nmds or pca funcs.

I have no idea what's going on, and I haven't had time to work with EcoPy in years.

Auerilas avatar Jul 31 '20 15:07 Auerilas