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

运行test脚本出错 #163

Open
Crane1043778796 opened this issue Jan 23, 2023 · 1 comment
Open

运行test脚本出错 #163

Crane1043778796 opened this issue Jan 23, 2023 · 1 comment

Comments

@Crane1043778796
Copy link

Traceback (most recent call last):
  File "E:/gait-set/GaitSet-master/test.py", line 90, in <module>
    main()
  File "E:/gait-set/GaitSet-master/test.py", line 39, in main
    m = initialization(conf, test=opt.cache)[0]
  File "E:\gait-set\GaitSet-master\model\initialization.py", line 57, in initialization
    train_source, test_source = initialize_data(config, train, test)
  File "E:\gait-set\GaitSet-master\model\initialization.py", line 15, in initialize_data
    train_source, test_source = load_data(**config['data'], cache=(train or test))
  File "E:\gait-set\GaitSet-master\model\utils\data_loader.py", line 45, in load_data
    np.save(pid_fname, pid_list)
  File "<__array_function__ internals>", line 200, in save
  File "D:\Anaconda3\lib\site-packages\numpy\lib\npyio.py", line 521, in save
    arr = np.asanyarray(arr)
ValueError: setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (2,) + inhomogeneous part.

其中dataloader.py约40行初

pid_list 

的内容是一个73长度的数组+一个长度50的数组把原数组分开了,请问你们也是这样吗 着急

@zjq1839
Copy link

zjq1839 commented Dec 16, 2024

numpy版本问题,我换到1.23.5解决了

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