question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ImportError: cannot import name '_validate_lengths'

See original GitHub issue

E:\repos\tensorflow>pushd E:\repos\tensorflow

E:\repos\tensorflow>ludwig experiment --data_csv translation.csv --model_definition_file model_definition.yaml e:\programdata\anaconda3\lib\site-packages\h5py_init_.py:36: FutureWarning: Conversion of the second argument of issubdtype from float to np.floating is deprecated. In future, it will be treated as np.float64 == np.dtype(float).type. from .conv import register_converters as register_converters Traceback (most recent call last): File “e:\programdata\anaconda3\lib\runpy.py”, line 193, in run_module_as_main “main”, mod_spec) File “e:\programdata\anaconda3\lib\runpy.py”, line 85, in run_code exec(code, run_globals) File "E:\ProgramData\Anaconda3\Scripts\ludwig.exe_main.py", line 5, in <module> File "e:\programdata\anaconda3\lib\site-packages\ludwig_init.py", line 16, in <module> from ludwig.api import LudwigModel File “e:\programdata\anaconda3\lib\site-packages\ludwig\api.py”, line 39, in <module> from ludwig.data.postprocessing import postprocess_df, postprocess File “e:\programdata\anaconda3\lib\site-packages\ludwig\data\postprocessing.py”, line 19, in <module> from ludwig.features.feature_registries import output_type_registry File “e:\programdata\anaconda3\lib\site-packages\ludwig\features\feature_registries.py”, line 33, in <module> from ludwig.features.image_feature import ImageBaseFeature File “e:\programdata\anaconda3\lib\site-packages\ludwig\features\image_feature.py”, line 24, in <module> from skimage.io import imread File "e:\programdata\anaconda3\lib\site-packages\skimage_init.py", line 158, in <module> from .util.dtype import * File "e:\programdata\anaconda3\lib\site-packages\skimage\util_init.py", line 7, in <module> from .arraycrop import crop File “e:\programdata\anaconda3\lib\site-packages\skimage\util\arraycrop.py”, line 8, in <module> from numpy.lib.arraypad import _validate_lengths ImportError: cannot import name ‘_validate_lengths’

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:6 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
athlonshicommented, Feb 13, 2019

scikit-image 0.14.2 and numpy 1.16.1 should work You may need to restart python environment after the update

0reactions
w4nderlustcommented, Feb 13, 2019

@jiangweiatgithub closing this, if you have another issue please open another one.

Read more comments on GitHub >

github_iconTop Results From Across the Web

ImportError: cannot import name '_validate_lengths'
I cross check the nump. It is up-to-date. I don't know the reason of this error. from numpy.lib.arraypad import _validate_lengths.
Read more >
cannot import name '_validate_lengths' · Issue #12744 - GitHub
it occurs only with numpy 1.16, numpy 1.15 works fine Using TensorFlow backend. Traceback (most recent call last): File ".
Read more >
PYTHON : ImportError: cannot import name '_validate_lengths'
PYTHON : ImportError : cannot import name ' _validate_lengths ' [ Gift : Animated Search Engine : https://www.hows.tech/p/recommended.html ] ...
Read more >
[开发技巧]·ImportError: cannot import name '_validate_lengths ...
错误是这个:from numpy.lib.arraypad import _validate_lengths. 推测应该是numpy更新过之后_validate_lengths被移除或者改名了.
Read more >
cannot import name 'export_saved_model - 腾讯云开发者社区
日更正式开始了,我会在Kuls和Python进击者两个频道日更文章,欢迎持续关注呀。 [开发技巧]·ImportError: cannot import name '_validate_lengths'解决 ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found