Open datar001 opened 3 years ago
Hi, please make sure you have successfully installed the following two libs:
block==0.0.5 block.bootstrap.pytorch==0.1.6
Hi, please make sure you have successfully installed the following two libs:
block==0.0.5 block.bootstrap.pytorch==0.1.6
I have installed these libs:
And I install all libs according to the requirements.txt.
Okay, are you using the right env for this repo? You can also check by vim a clean '.py' file and test:
from block import fusions
If it throws errors, then you have to re-install the libs.
The environment was achieved by the guidance in this repo. It seems to be right. python 3.6.8, torch1.6.0 I test this line in the python console and it also outputs the mistake.
Then i re-install the libs, it still outputs this mistake.
Not sure the problem here, perhaps you have to create a new env and setup the environment strictly following my guideline.
I have solved this problem just now. It seems to be caused by pip resource. When I re-install block and block.bootstrap.pytorch from mirrors.aliyun.com/pypi/simple rather than pypi.tuna.tsinghua.edu.cn/simple, this code runs well.
Great.
@datar001, could you share the commands you used to "re-install block and block.bootstrap.pytorch from mirrors.aliyun.com/pypi/simple" ?
-Thanks for the discussion
Pls try this:
pip install -i https://mirrors.aliyun.com/pypi/simple block==0.0.5
pip install -i https://mirrors.aliyun.com/pypi/simple block.bootstrap.pytorch==0.1.6
Thanks. I had to first install block and then block.bootstrap.pytorch from https://mirrors.aliyun.com/pypi/simple before loading from requirements.txt. (block and block.bootstrap.pytorch were commented out) And then it worked. Thanks again.
I found it's possible that block.bootstrap.pytorch
is shadowed by package block
, but there is no fusions
in block
package.
As a solution:
block
and block.bootstrap.pytorch
first.then fusions
can be found.
Suggestions
I think block
may be not necessary in project, while block.bootstrap.pytorch
is installed, so maybe remove it from requirements is a better choice.
Hi, Thanks for you share. It's a beautiful work. But it seems to have a problem when i run this code.
Traceback (most recent call last): File "main_qa.py", line 1, in
from videoqa import *
File "/media/ubuntu/HDD/zcy/NExT-QA-main/videoqa.py", line 2, in
from networks.VQAModel import EVQA, STVQA, CoMem, HME, HGA
File "/media/ubuntu/HDD/zcy/NExT-QA-main/networks/VQAModel/HGA.py", line 7, in
from block import fusions #pytorch >= 1.1.0
ImportError: cannot import name 'fusions'
It seems to be lack of a file named 'block.py' in the network folder.