dfm / tf.interp

Multivariate linear interpolation in TensorFlow
Apache License 2.0
38 stars 7 forks source link

Can't find regular_nd #2

Open ttgump opened 5 years ago

ttgump commented 5 years ago

Hi, After I install this package, I try to load in python:

from tfinterp import regular_nd
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ImportError: cannot import name 'regular_nd' from 'tfinterp' (/Users/tiantian/Documents/software/tf.interp/tfinterp/__init__.py)

Any ideas to fix it? Thanks.

astrobc1 commented 5 years ago

Same problem here. I'm looking for something that will perform 1d linear interpolation in tensorflow. But unfortunately I can't find a solution. Creating a custom one has the challenge of implementing the gradient.

dfm commented 5 years ago

This normally means that you are trying to load it from Python within the source directory. If you want to do that, you'll need to install using

python setup.py build_ext --inplace

or

python setup.py develop
astrobc1 commented 5 years ago

Aha! That worked. Thank you Dan!

dfm commented 5 years ago

Awesome - glad to hear it!