basic-pitch icon indicating copy to clipboard operation
basic-pitch copied to clipboard

cannot import name 'dtensor' from 'tensorflow.compat.v2.experimental'

Open masakiaota opened this issue 1 year ago • 1 comments

Situation

After basic-pitch installation with poetry, I tried to import predict_and_save. The version is 0.2.4.

from basic_pitch.inference import predict_and_save
>>> cannot import name 'dtensor' from 'tensorflow.compat.v2.experimental'

How to solve (Coping)

Downgrade the keras version to 2.6.0 (2.12.0 will be installed by default when you install basic-pich).

For example.

poetry add "keras==2.6.0"

See https://stackoverflow.com/questions/72255562/cannot-import-name-dtensor-from-tensorflow-compat-v2-experimental

How to solve (Fundamental)

Please solve the dependence problems...

masakiaota avatar May 05 '23 08:05 masakiaota

Hey! Thanks for letting us know about this. Would you mind posting your pyproject.toml file here? It would also be helpful to know what system you are running on.

bgenchel avatar May 19 '23 00:05 bgenchel