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

where is var edge_matrix_comp #3

Open
zdx3578 opened this issue Aug 10, 2024 · 3 comments
Open

where is var edge_matrix_comp #3

zdx3578 opened this issue Aug 10, 2024 · 3 comments

Comments

@zdx3578
Copy link

zdx3578 commented Aug 10, 2024

0
conda env create -f environment.yml ; this env so hard to create

github codespace ubuntu 20.04.6 LTS,conda python 3.7.16 just run;

1
File "/workspaces/ViRel/args.py", line 142, in standardize_args
if not args.max_count:
AttributeError: 'Namespace' object has no attribute 'max_count'

fix by run args; python relation_analogy.py --yaml config/main3.yaml

2
def get_root_dir():
dirname = os.getcwd()
#dirname_split = dirname.split("/")
#index = dirname_split.index("reasoning")
#dirname = "/".join(dirname_split[:index + 1])
return dirname

3 relation_analogy.py add one line code. " from BabyARC.code.dataset.objects import Object"

@zdx3578
Copy link
Author

zdx3578 commented Aug 12, 2024

python3.9 env pip req.txt error:

Requirements should be satisfied by a PEP 517 installer.
If you are using pip, you can try pip install --use-pep517.

@zdx3578
Copy link
Author

zdx3578 commented Aug 12, 2024

req3.txt
req2.txt

参考命令:
470 conda install cudatoolkit=11.3 -c pytorch -c conda-forge
477 conda install cudatoolkit=11.3 -c pytorch -c conda-forge
478 pip install torch-scatter==2.0.8
480 conda install pytorch-scatter -c pyg
481 conda install torch-scatter -c pyg
482 pip install torch-scatter==2.0.8
483 pip install torch-sparse==0.6.12
484 pip install torch-sparse

mkdir -p /dfs/user/tailin/.results/Datasets/
561 mkdir ../cache
562 mkdir cache
mkdir concept_env/datasets -p

@zdx3578
Copy link
Author

zdx3578 commented Aug 12, 2024

Epoch: 9 T-dur 18.74 T-loss 3.430 T-acc 0.000 V-dur 0.00 V-loss 0.000 V-acc 0.000
Traceback (most recent call last):
File "/home/zdx/miniconda3/envs/py37virel/lib/python3.7/runpy.py", line 193, in _run_module_as_main
"main", mod_spec)
File "/home/zdx/miniconda3/envs/py37virel/lib/python3.7/runpy.py", line 85, in _run_code
exec(code, run_globals)
File "/home/zdx/.vscode-server/extensions/ms-python.debugpy-2024.10.0-linux-x64/bundled/libs/debugpy/adapter/../../debugpy/launcher/../../debugpy/main.py", line 39, in
cli.main()
File "/home/zdx/.vscode-server/extensions/ms-python.debugpy-2024.10.0-linux-x64/bundled/libs/debugpy/adapter/../../debugpy/launcher/../../debugpy/../debugpy/server/cli.py", line 430, in main
run()
File "/home/zdx/.vscode-server/extensions/ms-python.debugpy-2024.10.0-linux-x64/bundled/libs/debugpy/adapter/../../debugpy/launcher/../../debugpy/../debugpy/server/cli.py", line 284, in run_file
runpy.run_path(target, run_name="main")
File "/home/zdx/.vscode-server/extensions/ms-python.debugpy-2024.10.0-linux-x64/bundled/libs/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_runpy.py", line 322, in run_path
pkg_name=pkg_name, script_name=fname)
File "/home/zdx/.vscode-server/extensions/ms-python.debugpy-2024.10.0-linux-x64/bundled/libs/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_runpy.py", line 136, in _run_module_code
mod_name, mod_spec, pkg_name, script_name)
File "/home/zdx/.vscode-server/extensions/ms-python.debugpy-2024.10.0-linux-x64/bundled/libs/debugpy/_vendored/pydevd/_pydevd_bundle/pydevd_runpy.py", line 124, in _run_code
exec(code, run_globals)
File "/home/zdx/github/VSAHDC/virel/relation_analogy.py", line 802, in
main()
File "/home/zdx/github/VSAHDC/virel/relation_analogy.py", line 119, in main
val_dur, protos, accTr, accVal, taskAccTr, taskAccVal, edgeDistTrStr, edgeDistValStr = evaluate(val_loader, train_loader_edge, val_loader_edge, edge_configs, model, task_loss_fn, epoch, start_step, writer, data_record, args, device, args.padding_objs, args.total_tasks)
File "/home/zdx/github/VSAHDC/virel/relation_analogy.py", line 268, in evaluate
relTaskDistTr, taskDistTr, relDistTr, protos, labelsTr, edgeMaskTr, taskIdsTr = edge_dist_fast(train_loader_edge, model, args, device, False, protos=protos)
File "/home/zdx/github/VSAHDC/virel/relation_analogy.py", line 524, in edge_dist_fast
uniq_edges_comp, counts = torch.unique(edge_matrix_comp, return_counts=True, dim=0)
NameError: name 'edge_matrix_comp' is not defined
(py37virel) ➜ VSAHDC

@zdx3578 zdx3578 changed the title conda env create -f environment.yml ; this env so hard to create where is var edge_matrix_comp Aug 12, 2024
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

1 participant