Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

change np.float #137

Open
byungjinku opened this issue Jan 12, 2024 · 1 comment
Open

change np.float #137

byungjinku opened this issue Jan 12, 2024 · 1 comment

Comments

@byungjinku
Copy link

HI
where I have to change for 'float' ?
here the error message

(laneatt) bjku@bjku:~/LaneATT$ python main.py train --exp_name laneatt_r34_tusimple --cfg cfgs/laneatt_tusimple_resnet34.yml
Traceback (most recent call last):
File "main.py", line 6, in
from lib.config import Config
File "/home/bjku/LaneATT/lib/config.py", line 4, in
import lib.datasets as datasets
File "/home/bjku/LaneATT/lib/datasets/init.py", line 1, in
from .lane_dataset import LaneDataset
File "/home/bjku/LaneATT/lib/datasets/lane_dataset.py", line 15, in
from .tusimple import TuSimple
File "/home/bjku/LaneATT/lib/datasets/tusimple.py", line 8, in
from utils.tusimple_metric import LaneEval
File "/home/bjku/LaneATT/utils/tusimple_metric.py", line 4, in
from sklearn.linear_model import LinearRegression
File "/home/bjku/miniconda3/envs/laneatt/lib/python3.8/site-packages/sklearn/linear_model/init.py", line 11, in
from ._least_angle import (Lars, LassoLars, lars_path, lars_path_gram, LarsCV,
File "/home/bjku/miniconda3/envs/laneatt/lib/python3.8/site-packages/sklearn/linear_model/_least_angle.py", line 34, in
method='lar', copy_X=True, eps=np.finfo(np.float).eps,
File "/home/bjku/miniconda3/envs/laneatt/lib/python3.8/site-packages/numpy/init.py", line 305, in getattr
raise AttributeError(former_attrs[attr])
AttributeError: module 'numpy' has no attribute 'float'.
np.float was a deprecated alias for the builtin float. To avoid this error in existing code, use float by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use np.float64 here.
The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at:
https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations

@Aayushktyagi
Copy link

pip install numpy==1.19 helps here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants