Skip to content

docs: bit misspell print label util script Installation section README #1

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ This is the TorchDrug implementation of [ULTRA], a foundation model for KG reaso
## Installation ##

You may install the dependencies via either conda or pip.
Ultra (TorchDrug) is compatible with Python 3.7/3.8/3.9, PyTorch 1.13 and PyG 2.3 (CUDA 11.7 or later wnen running on GPUs). If you are on a Mac, you may omit the CUDA toolkit requirements (tested with PyTorch 2.0 with the relevant `torch-scatter` version on Mac M2).
Ultra (TorchDrug) is compatible with Python 3.7/3.8/3.9, PyTorch 1.13 and PyG 2.3 (CUDA 11.7 or later when running on GPUs). If you are on a Mac, you may omit the CUDA toolkit requirements (tested with PyTorch 2.0 with the relevant `torch-scatter` version on Mac M2).

### From Conda ###

Expand Down Expand Up @@ -143,7 +143,7 @@ To run ULTRA with multiple GPUs, use the following commands (eg, 4 GPUs per node
python -m torch.distributed.launch --nproc_per_node=4 script/run_full.py -c config/transductive/pretrain.yaml --gpus [0,1,2,3]
```

Multi-node setup might work as well(not tested):
Multi-node setup might work as well (not tested):
```bash
python -m torch.distributed.launch --nnodes=4 --nproc_per_node=4 script/pretrain.py -c config/transductive/pretrain.yaml --gpus [0,1,2,3,0,1,2,3,0,1,2,3,0,1,2,3]
```
Expand Down
4 changes: 2 additions & 2 deletions ultra/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ def safe_load(solver, checkpoint, fix_reasoner=False, drop_optimizer=True):
if not fix_reasoner:
solver.optimizer.load_state_dict(state["optimizer"])
except:
print("\n\n\n\nwarninig: loaded state dict has a different number of parameter groups\n\n\n\n")
print("\n\n\n\nwarning: loaded state dict has a different number of parameter groups\n\n\n\n")

for state in solver.optimizer.state.values():
for k, v in state.items():
Expand Down Expand Up @@ -322,4 +322,4 @@ def clean_save(solver, checkpoint):
}
torch.save(state, checkpoint)

comm.synchronize()
comm.synchronize()