Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

module 'numpy' has no attribute 'object' [closed]

I am getting below error when running mlflow app

raise AttributeError("module {!r} has no attribute " AttributeError: module 'numpy' has no attribute 'object'

Can someone help me with this

like image 247
Divya Avatar asked Sep 01 '25 10:09

Divya


2 Answers

Since version 1.24 of numpy, np.object is deprecated, and needs to be replaced with object (cf. numpy release notes).

You either need to update this in your code, or another package you're using needs to be updated (not possible to answer without more information).

One (dirty) workaround for now would be to fix your numpy version to the last version still supporting np.object with pip install numpy==1.23.4

like image 87
Jan Avatar answered Sep 03 '25 00:09

Jan


Try :

pip3 install numpy==1.23.5

I was facing same issue with numpy 1.24.2

like image 33
Keval Avatar answered Sep 02 '25 23:09

Keval