no module name datasets
When i ran /Ask-Anything-main/video_chat2/tasks/train_qformer.py on remote servers, it said ModuleNotFoundError: No module named 'dataset'. However, there is no error or warning in the code and the code path is correct.
Please ensure that the path you are running is under the video_chat2 folder.
If not, you need to add /root/Ask-Anything-main/video_chat2/ to your PYTHONPATH. You can execute export PYTHONPATH=/root/Ask-Anything-main/video_chat2/:$PYTHONPATH in the command line before running.
In addition, it is recommended that you refer to https://github.com/OpenGVLab/Ask-Anything/blob/main/video_chat2/scripts/videochat_vicuna/run_7b_stage1.sh to train the qformer. If you are not using slurm, you can refer to the following:
NNODE=4
OUTPUT_DIR="$(dirname $0)/$JOB_NAME"
torchrun --rdzv_endpoint=${MASTER_NODE}:${MASTER_PORT} --nnodes=${NNODE} \
--nproc_per_node=${NUM_GPUS} \
--rdzv_backend=c10d \
tasks/train_qformer.py \
$(dirname $0)/config_7b_stage1.py \
output_dir ${OUTPUT_DIR}
当我在远程服务器上运行 /Ask-Anything-main/video_chat2/tasks/train_qformer.py 时,它说 ModuleNotFoundError: No module named 'dataset'。但是,代码中没有错误或警告,并且代码路径是正确的。
请问解决了吗
当我在远程服务器上运行 /Ask-Anything-main/video_chat2/tasks/train_qformer.py 时,它说 ModuleNotFoundError: No module named 'dataset'。但是,代码中没有错误或警告,并且代码路径是正确的。
请问解决了吗
@zhou186 您遇到类似的问题了吗?我想上面的回答应该可以解决这个问题https://github.com/OpenGVLab/Ask-Anything/issues/225#issuecomment-2302083025
当我在远程服务器上运行 /Ask-Anything-main/video_chat2/tasks/train_qformer.py 时,它说 ModuleNotFoundError: No module named 'dataset'。但是,代码中没有错误或警告,并且代码路径是正确的。
请问解决了吗
您遇到类似的问题了吗?我想上面的回答应该可以解决这个问题#225 (comment) 您好,正在运行的路径确实位于video_chat2文件夹下,我在远程服务器上运行的demo.py文件,报错ModuleNotFoundError: No module named 'dataset'。翻了翻文件夹,确实没有找到dataset
当我在远程服务器上运行 /Ask-Anything-main/video_chat2/tasks/train_qformer.py 时,它说 ModuleNotFoundError: No module named 'dataset'。但是,代码中没有错误或警告,并且代码路径是正确的。
请问解决了吗
您遇到类似的问题了吗?我想上面的回答应该可以解决这个问题#225 (comment) 您好,正在运行的路径确实位于video_chat2文件夹下,我在远程服务器上运行的demo.py文件,报错ModuleNotFoundError: No module named 'dataset'。翻了翻文件夹,确实没有找到dataset
@zhou186 这个您需要在上一层目录执行 python demo/demo.py即可
当我在远程服务器上运行 /Ask-Anything-main/video_chat2/tasks/train_qformer.py 时,它说 ModuleNotFoundError: No module named 'dataset'。但是,代码中没有错误或警告,并且代码路径是正确的。
请问解决了吗
您遇到类似的问题了吗?我想上面的回答应该可以解决这个问题#225 (comment) 您好,正在运行的路径确实位于video_chat2文件夹下,我在远程服务器上运行的demo.py文件,报错ModuleNotFoundError: No module named 'dataset'。翻了翻文件夹,确实没有找到dataset
@zhou186 这个您需要在上一层目录执行
python demo/demo.py即可
非常感谢您的回复,但我又遇到一个新问题
返回上一级运行demo.py后报错ModuleNotFoundError: No module named 'model'
video_chat2文件夹里似乎只有models,且models里没有需要导入的VideoChat2_it_vicuna
@zhou186 应该是有的,还请您再试试 https://github.com/OpenGVLab/Ask-Anything/blob/37db036dfc7e8188ab0411691070c643cd21f7b6/video_chat2/demo/demo.py#L11
它来自于: https://github.com/OpenGVLab/Ask-Anything/blob/37db036dfc7e8188ab0411691070c643cd21f7b6/video_chat2/models/init.py#L4
@zhou186 应该是有的,还请您再试试
https://github.com/OpenGVLab/Ask-Anything/blob/37db036dfc7e8188ab0411691070c643cd21f7b6/video_chat2/demo/demo.py#L11
它来自于:
https://github.com/OpenGVLab/Ask-Anything/blob/37db036dfc7e8188ab0411691070c643cd21f7b6/video_chat2/models/init.py#L4
非常感谢您的回复,请问可以添加一下您的联系方式吗,在这上面回复消息有些慢
谢谢!
Hi, we will close this issue.
Feel free to contact us if you have other questions.

