-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Loading status checks…
Merge branch 'main' of https://github.com/pyt-team/TopoBenchmarkX
Showing
176 changed files
with
6,699 additions
and
3,575 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
/logs | ||
/datasets/graph | ||
.ruff_cache |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
# #!/bin/bash | ||
|
||
mkdir -p ~/miniconda3 | ||
wget https://repo.anaconda.com/miniconda/Miniconda3-latest-Linux-x86_64.sh -O ~/miniconda3/miniconda.sh | ||
bash ~/miniconda3/miniconda.sh -b -u -p ~/miniconda3 | ||
rm -rf ~/miniconda3/miniconda.sh | ||
|
||
~/miniconda3/bin/conda init bash | ||
|
||
#conda create -n topox python=3.11.3 | ||
#conda activate topox |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,10 @@ | ||
_target_: topobenchmarkx.io.load.loaders.GraphLoader | ||
|
||
# USE python train.py dataset.transforms.one_hot_node_degree_features.degrees_fields=x to run this config | ||
|
||
defaults: | ||
- transforms/data_manipulations: node_feat_to_float | ||
- transforms/data_manipulations: node_degrees | ||
- transforms/[email protected]_hot_node_degree_features: one_hot_node_degree_features | ||
- transforms: ${get_default_transform:graph,${model}} | ||
|
||
# Data definition | ||
|
@@ -13,14 +16,15 @@ parameters: | |
data_split_dir: ${paths.data_dir}data_splits/${dataset.parameters.data_name} | ||
|
||
# Dataset parameters | ||
num_features: 1 # here basically I specify the initial num features in mutang at x aka x_0 | ||
num_features: 21 # torch_geometric ZINC dataset has 21 atom types | ||
max_node_degree: 20 # Use it to one_hot encode node degrees. Additional parameter to run dataset.transforms.one_hot_node_degree_features.degrees_fields=x | ||
num_classes: 1 | ||
task: regression | ||
loss_type: mse | ||
monitor_metric: mae | ||
task_level: graph | ||
data_seed: 0 | ||
split_type: 'fixed' # either k-fold or test | ||
split_type: 'fixed' # ZINC accept only <fixed> split | ||
#k: 10 # for k-Fold Cross-Validation | ||
|
||
# Dataloader parameters | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
configs/dataset/transforms/data_manipulations/node_degrees.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
_target_: topobenchmarkx.transforms.data_transform.DataTransform | ||
transform_name: "NodeDegrees" | ||
transform_type: "data manipulation" | ||
selected_fields: ["edge_index", "incidence"] #"incidence" | ||
selected_fields: ["edge_index"] # "incidence" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 1 addition & 2 deletions
3
configs/dataset/transforms/graph2cell_lifting/cell_cycles.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,6 @@ | ||
_target_: topobenchmarkx.transforms.data_transform.DataTransform | ||
transform_type: 'lifting' | ||
transform_name: "CellCyclesLifting" | ||
k_value: 1 | ||
complex_dim: ${oc.select:dataset.parameters.max_dim_if_lifted,3} | ||
max_cell_length: 6 | ||
max_cell_length: 10 | ||
preserve_edge_attr: ${oc.select:dataset.parameters.preserve_edge_attr_if_lifted,False} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 17 additions & 11 deletions
28
configs/model/cell/cwn_dcm.yaml → configs/model/cell/cccn.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
#!/bin/bash -l | ||
|
||
pip install --upgrade pip | ||
pip install -e '.[all]' | ||
|
||
pip install --no-dependencies git+https://github.com/pyt-team/TopoNetX.git | ||
pip install --no-dependencies git+https://github.com/pyt-team/TopoModelX.git | ||
pip install --no-dependencies git+https://github.com/pyt-team/TopoEmbedX.git | ||
|
||
# Note that not all combinations of torch and CUDA are available | ||
# See https://github.com/pyg-team/pyg-lib to check the configuration that works for you | ||
TORCH="2.3.0" # available options: 1.12.0, 1.13.0, 2.0.0, 2.1.0, 2.2.0, or 2.3.0 | ||
CUDA="cu121" # if available, select the CUDA version suitable for your system | ||
# available options: cpu, cu102, cu113, cu116, cu117, cu118, or cu121 | ||
pip install torch==${TORCH} --extra-index-url https://download.pytorch.org/whl/${CUDA} | ||
pip install lightning torch_geometric==2.4.0 | ||
pip install pyg-lib torch-scatter torch-sparse torch-cluster -f https://data.pyg.org/whl/torch-${TORCH}+${CUDA}.html | ||
pytest | ||
|
||
pre-commit install |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#!/bin/sh | ||
|
||
# Run ruff to check for issues and fix them | ||
ruff check . --fix | ||
|
||
# Run docformatter to reformat docstrings and comments | ||
docformatter --in-place --recursive --wrap-summaries 79 --wrap-descriptions 79 . | ||
|
||
# Run black to format the code | ||
black . |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,147 @@ | ||
# Description: Main experiment script for GCN model. | ||
# ----Node regression datasets: US County Demographics---- | ||
task_variables=( 'Election' 'MedianIncome' 'MigraRate' 'BirthRate' 'DeathRate' 'BachelorRate' 'UnemploymentRate' ) | ||
|
||
for task_variable in ${task_variables[*]} | ||
do | ||
python train.py \ | ||
dataset=us_country_demos \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.task_variable=$task_variable \ | ||
model=cell/can \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=500 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
done | ||
|
||
# ----Cocitation datasets---- | ||
datasets=( 'cocitation_cora' 'cocitation_citeseer' 'cocitation_pubmed' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
model=cell/can \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.n_layers=1,2 \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=25 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# # ----Graph regression dataset---- | ||
# # Train on ZINC dataset | ||
# python train.py \ | ||
# dataset=ZINC \ | ||
# seed=42,3,5,23,150 \ | ||
# model=cell/can \ | ||
# model.optimizer.lr=0.01,0.001 \ | ||
# model.optimizer.weight_decay=0 \ | ||
# model.feature_encoder.out_channels=32,64,128 \ | ||
# model.backbone.n_layers=2,4 \ | ||
# model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
# dataset.parameters.batch_size=128,256 \ | ||
# dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
# dataset.parameters.data_seed=0 \ | ||
# dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
# model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
# logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
# trainer.max_epochs=500 \ | ||
# trainer.min_epochs=50 \ | ||
# callbacks.early_stopping.min_delta=0.005 \ | ||
# trainer.check_val_every_n_epoch=5 \ | ||
# callbacks.early_stopping.patience=10 \ | ||
# tags="[MainExperiment]" \ | ||
# --multirun | ||
|
||
# ----TU graph datasets---- | ||
# MUTAG have very few samples, so we use a smaller batch size | ||
# Train on MUTAG dataset | ||
python train.py \ | ||
dataset=MUTAG \ | ||
model=cell/can \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=32,64 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
callbacks.early_stopping.patience=25 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# Train rest of the TU graph datasets | ||
datasets=( 'PROTEINS_TU' 'NCI1' 'NCI109' 'IMDB-BINARY' 'IMDB-MULTI' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=cell/can \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
--multirun | ||
done | ||
|
||
# ----Heterophilic datasets---- | ||
|
||
datasets=( roman_empire minesweeper ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=cell/can \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=1 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,147 @@ | ||
# Description: Main experiment script for GCN model. | ||
# ----Node regression datasets: US County Demographics---- | ||
task_variables=( 'Election' 'MedianIncome' 'MigraRate' 'BirthRate' 'DeathRate' 'BachelorRate' 'UnemploymentRate' ) | ||
|
||
for task_variable in ${task_variables[*]} | ||
do | ||
python train.py \ | ||
dataset=us_country_demos \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.task_variable=$task_variable \ | ||
model=cell/cccn \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=500 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
done | ||
|
||
# ----Cocitation datasets---- | ||
datasets=( 'cocitation_cora' 'cocitation_citeseer' 'cocitation_pubmed' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
model=cell/cccn \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.n_layers=1,2 \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=25 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# # ----Graph regression dataset---- | ||
# # Train on ZINC dataset | ||
# python train.py \ | ||
# dataset=ZINC \ | ||
# seed=42,3,5,23,150 \ | ||
# model=cell/cccn \ | ||
# model.optimizer.lr=0.01,0.001 \ | ||
# model.optimizer.weight_decay=0 \ | ||
# model.feature_encoder.out_channels=32,64,128 \ | ||
# model.backbone.n_layers=2,4 \ | ||
# model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
# dataset.parameters.batch_size=128,256 \ | ||
# dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
# dataset.parameters.data_seed=0 \ | ||
# dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
# model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
# logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
# trainer.max_epochs=500 \ | ||
# trainer.min_epochs=50 \ | ||
# callbacks.early_stopping.min_delta=0.005 \ | ||
# trainer.check_val_every_n_epoch=5 \ | ||
# callbacks.early_stopping.patience=10 \ | ||
# tags="[MainExperiment]" \ | ||
# --multirun | ||
|
||
# ----TU graph datasets---- | ||
# MUTAG have very few samples, so we use a smaller batch size | ||
# Train on MUTAG dataset | ||
python train.py \ | ||
dataset=MUTAG \ | ||
model=cell/cccn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=32,64 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
callbacks.early_stopping.patience=25 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# Train rest of the TU graph datasets | ||
datasets=( 'PROTEINS_TU' 'NCI1' 'NCI109' 'IMDB-BINARY' 'IMDB-MULTI' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=cell/cccn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
--multirun | ||
done | ||
|
||
# ----Heterophilic datasets---- | ||
|
||
datasets=( roman_empire minesweeper ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=cell/cccn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=1 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,147 @@ | ||
# Description: Main experiment script for GCN model. | ||
# ----Node regression datasets: US County Demographics---- | ||
task_variables=( 'Election' 'MedianIncome' 'MigraRate' 'BirthRate' 'DeathRate' 'BachelorRate' 'UnemploymentRate' ) | ||
|
||
for task_variable in ${task_variables[*]} | ||
do | ||
python train.py \ | ||
dataset=us_country_demos \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.task_variable=$task_variable \ | ||
model=cell/ccxn \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=500 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
done | ||
|
||
# ----Cocitation datasets---- | ||
datasets=( 'cocitation_cora' 'cocitation_citeseer' 'cocitation_pubmed' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
model=cell/ccxn \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.n_layers=1,2 \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=25 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# # ----Graph regression dataset---- | ||
# # Train on ZINC dataset | ||
# python train.py \ | ||
# dataset=ZINC \ | ||
# seed=42,3,5,23,150 \ | ||
# model=cell/ccxn \ | ||
# model.optimizer.lr=0.01,0.001 \ | ||
# model.optimizer.weight_decay=0 \ | ||
# model.feature_encoder.out_channels=32,64,128 \ | ||
# model.backbone.n_layers=2,4 \ | ||
# model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
# dataset.parameters.batch_size=128,256 \ | ||
# dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
# dataset.parameters.data_seed=0 \ | ||
# dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
# model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
# logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
# trainer.max_epochs=500 \ | ||
# trainer.min_epochs=50 \ | ||
# callbacks.early_stopping.min_delta=0.005 \ | ||
# trainer.check_val_every_n_epoch=5 \ | ||
# callbacks.early_stopping.patience=10 \ | ||
# tags="[MainExperiment]" \ | ||
# --multirun | ||
|
||
# ----TU graph datasets---- | ||
# MUTAG have very few samples, so we use a smaller batch size | ||
# Train on MUTAG dataset | ||
python train.py \ | ||
dataset=MUTAG \ | ||
model=cell/ccxn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=32,64 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
callbacks.early_stopping.patience=25 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# Train rest of the TU graph datasets | ||
datasets=( 'PROTEINS_TU' 'NCI1' 'NCI109' 'IMDB-BINARY' 'IMDB-MULTI' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=cell/ccxn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
--multirun | ||
done | ||
|
||
# ----Heterophilic datasets---- | ||
|
||
datasets=( roman_empire minesweeper ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=cell/ccxn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=1 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,147 @@ | ||
# Description: Main experiment script for GCN model. | ||
# ----Node regression datasets: US County Demographics---- | ||
task_variables=( 'Election' 'MedianIncome' 'MigraRate' 'BirthRate' 'DeathRate' 'BachelorRate' 'UnemploymentRate' ) | ||
|
||
for task_variable in ${task_variables[*]} | ||
do | ||
python train.py \ | ||
dataset=us_country_demos \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.task_variable=$task_variable \ | ||
model=cell/cwn \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=500 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
done | ||
|
||
# ----Cocitation datasets---- | ||
datasets=( 'cocitation_cora' 'cocitation_citeseer' 'cocitation_pubmed' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
model=cell/cwn \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.n_layers=1,2 \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=25 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# # ----Graph regression dataset---- | ||
# # Train on ZINC dataset | ||
# python train.py \ | ||
# dataset=ZINC \ | ||
# seed=42,3,5,23,150 \ | ||
# model=cell/cwn \ | ||
# model.optimizer.lr=0.01,0.001 \ | ||
# model.optimizer.weight_decay=0 \ | ||
# model.feature_encoder.out_channels=32,64,128 \ | ||
# model.backbone.n_layers=2,4 \ | ||
# model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
# dataset.parameters.batch_size=128,256 \ | ||
# dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
# dataset.parameters.data_seed=0 \ | ||
# dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
# model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
# logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
# trainer.max_epochs=500 \ | ||
# trainer.min_epochs=50 \ | ||
# callbacks.early_stopping.min_delta=0.005 \ | ||
# trainer.check_val_every_n_epoch=5 \ | ||
# callbacks.early_stopping.patience=10 \ | ||
# tags="[MainExperiment]" \ | ||
# --multirun | ||
|
||
# ----TU graph datasets---- | ||
# MUTAG have very few samples, so we use a smaller batch size | ||
# Train on MUTAG dataset | ||
python train.py \ | ||
dataset=MUTAG \ | ||
model=cell/cwn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=32,64 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
callbacks.early_stopping.patience=25 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# Train rest of the TU graph datasets | ||
datasets=( 'PROTEINS_TU' 'NCI1' 'NCI109' 'IMDB-BINARY' 'IMDB-MULTI' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=cell/cwn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
--multirun | ||
done | ||
|
||
# ----Heterophilic datasets---- | ||
|
||
datasets=( roman_empire minesweeper ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=cell/cwn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.batch_size=1 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,103 @@ | ||
# ----Graph regression dataset---- | ||
# Train on ZINC dataset | ||
|
||
# CWN | ||
python train.py \ | ||
dataset=ZINC \ | ||
seed=42,3,5,23,150 \ | ||
model=cell/cwn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.optimizer.weight_decay=0 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=2,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
dataset.parameters.data_seed=0 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
callbacks.early_stopping.min_delta=0.005 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# CCXN | ||
python train.py \ | ||
dataset=ZINC \ | ||
seed=42,3,5,23,150 \ | ||
model=cell/ccxn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.optimizer.weight_decay=0 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=2,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
dataset.parameters.data_seed=0 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
callbacks.early_stopping.min_delta=0.005 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# CCCN | ||
python train.py \ | ||
dataset=ZINC \ | ||
seed=42,3,5,23,150 \ | ||
model=cell/cccn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.optimizer.weight_decay=0 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=2,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
dataset.parameters.data_seed=0 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
callbacks.early_stopping.min_delta=0.005 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
|
||
# CAN | ||
|
||
python train.py \ | ||
dataset=ZINC \ | ||
seed=42,3,5,23,150 \ | ||
model=cell/can \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.optimizer.weight_decay=0 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=2,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
dataset.parameters.data_seed=0 \ | ||
dataset.transforms.graph2cell_lifting.max_cell_length=10 \ | ||
model.readout.readout_name="NoReadOut,PropagateSignalDown" \ | ||
logger.wandb.project=TopoBenchmarkX_Cellular \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
callbacks.early_stopping.min_delta=0.005 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
|
||
# REDDIT BINARY for all |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,136 @@ | ||
# Description: Main experiment script for GCN model. | ||
# ----Node regression datasets: US County Demographics---- | ||
task_variables=( 'Election' 'MedianIncome' 'MigraRate' 'BirthRate' 'DeathRate' 'BachelorRate' 'UnemploymentRate' ) | ||
|
||
for task_variable in ${task_variables[*]} | ||
do | ||
python train.py \ | ||
dataset=us_country_demos \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.task_variable=$task_variable \ | ||
model=graph/gat \ | ||
model.feature_encoder.out_channels="32,64,128" \ | ||
model.feature_encoder.proj_dropout="0,0.25,0.5" \ | ||
model.backbone.num_layers="1,2,3,4" \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=500 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
done | ||
|
||
# ----Cocitation datasets---- | ||
datasets=( 'cocitation_cora' 'cocitation_citeseer' 'cocitation_pubmed' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
model=graph/gat \ | ||
model.feature_encoder.out_channels="32,64,128" \ | ||
model.feature_encoder.proj_dropout="0,0.25,0.5" \ | ||
model.backbone.num_layers="1,2" \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=25 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# ----Graph regression dataset---- | ||
# Train on ZINC dataset | ||
python train.py \ | ||
dataset=ZINC \ | ||
seed=42,3,5,23,150 \ | ||
model=graph/gat \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.optimizer.weight_decay=0 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=2,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
dataset.parameters.data_seed=0 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
callbacks.early_stopping.min_delta=0.005 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# ----Heterophilic datasets---- | ||
|
||
datasets=( roman_empire amazon_ratings tolokers questions minesweeper ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=graph/gat \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# ----TU graph datasets---- | ||
# MUTAG have very few samples, so we use a smaller batch size | ||
# Train on MUTAG dataset | ||
python train.py \ | ||
dataset=MUTAG \ | ||
model=graph/gat \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=32,64 \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
callbacks.early_stopping.patience=25 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# Train rest of the TU graph datasets | ||
datasets=( 'PROTEINS_TU' 'NCI1' 'NCI109' 'REDDIT-BINARY' 'IMDB-BINARY' 'IMDB-MULTI' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=graph/gat \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
--multirun | ||
done | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,136 @@ | ||
# Description: Main experiment script for GCN model. | ||
# ----Node regression datasets: US County Demographics---- | ||
task_variables=( 'Election' 'MedianIncome' 'MigraRate' 'BirthRate' 'DeathRate' 'BachelorRate' 'UnemploymentRate' ) | ||
|
||
for task_variable in ${task_variables[*]} | ||
do | ||
python train.py \ | ||
dataset=us_country_demos \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.task_variable=$task_variable \ | ||
model=graph/gcn \ | ||
model.feature_encoder.out_channels="32,64,128" \ | ||
model.feature_encoder.proj_dropout="0,0.25,0.5" \ | ||
model.backbone.num_layers="1,2,3,4" \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=500 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
done | ||
|
||
# ----Cocitation datasets---- | ||
datasets=( 'cocitation_cora' 'cocitation_citeseer' 'cocitation_pubmed' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
model=graph/gcn \ | ||
model.feature_encoder.out_channels="32,64,128" \ | ||
model.feature_encoder.proj_dropout="0,0.25,0.5" \ | ||
model.backbone.num_layers="1,2" \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=25 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# ----Graph regression dataset---- | ||
# Train on ZINC dataset | ||
python train.py \ | ||
dataset=ZINC \ | ||
seed=42,3,5,23,150 \ | ||
model=graph/gcn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.optimizer.weight_decay=0 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=2,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
dataset.parameters.data_seed=0 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
callbacks.early_stopping.min_delta=0.005 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# ----Heterophilic datasets---- | ||
|
||
datasets=( roman_empire amazon_ratings tolokers questions minesweeper ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=graph/gcn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=1 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# ----TU graph datasets---- | ||
# MUTAG have very few samples, so we use a smaller batch size | ||
# Train on MUTAG dataset | ||
python train.py \ | ||
dataset=MUTAG \ | ||
model=graph/gcn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=32,64 \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
callbacks.early_stopping.patience=25 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# Train rest of the TU graph datasets | ||
datasets=( 'PROTEINS_TU' 'NCI1' 'NCI109' 'REDDIT-BINARY' 'IMDB-BINARY' 'IMDB-MULTI' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=graph/gcn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
--multirun | ||
done | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,136 @@ | ||
# Description: Main experiment script for GCN model. | ||
# ----Node regression datasets: US County Demographics---- | ||
task_variables=( 'Election' 'MedianIncome' 'MigraRate' 'BirthRate' 'DeathRate' 'BachelorRate' 'UnemploymentRate' ) | ||
|
||
for task_variable in ${task_variables[*]} | ||
do | ||
python train.py \ | ||
dataset=us_country_demos \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.task_variable=$task_variable \ | ||
model=graph/gin \ | ||
model.feature_encoder.out_channels="32,64,128" \ | ||
model.feature_encoder.proj_dropout="0,0.25,0.5" \ | ||
model.backbone.num_layers="1,2,3,4" \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=500 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
done | ||
|
||
# ----Cocitation datasets---- | ||
datasets=( 'cocitation_cora' 'cocitation_citeseer' 'cocitation_pubmed' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
model=graph/gin \ | ||
model.feature_encoder.out_channels="32,64,128" \ | ||
model.feature_encoder.proj_dropout="0,0.25,0.5" \ | ||
model.backbone.num_layers="1,2" \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=25 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# ----Graph regression dataset---- | ||
# Train on ZINC dataset | ||
python train.py \ | ||
dataset=ZINC \ | ||
seed=42,3,5,23,150 \ | ||
model=graph/gin \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.optimizer.weight_decay=0 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=2,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
dataset.parameters.data_seed=0 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
callbacks.early_stopping.min_delta=0.005 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# ----Heterophilic datasets---- | ||
|
||
datasets=( roman_empire amazon_ratings tolokers questions minesweeper ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=graph/gin \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# ----TU graph datasets---- | ||
# MUTAG have very few samples, so we use a smaller batch size | ||
# Train on MUTAG dataset | ||
python train.py \ | ||
dataset=MUTAG \ | ||
model=graph/gin \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=32,64 \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
callbacks.early_stopping.patience=25 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# Train rest of the TU graph datasets | ||
datasets=( 'PROTEINS_TU' 'NCI1' 'NCI109' 'REDDIT-BINARY' 'IMDB-BINARY' 'IMDB-MULTI' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=graph/gin \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
logger.wandb.project=TopoBenchmarkX_Graph \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
--multirun | ||
done | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,136 @@ | ||
# Description: Main experiment script for GCN model. | ||
# ----Node regression datasets: US County Demographics---- | ||
task_variables=( 'Election' 'MedianIncome' 'MigraRate' 'BirthRate' 'DeathRate' 'BachelorRate' 'UnemploymentRate' ) | ||
|
||
for task_variable in ${task_variables[*]} | ||
do | ||
python train.py \ | ||
dataset=us_country_demos \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.task_variable=$task_variable \ | ||
model=hypergraph/allsettransformer \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.n_layers="1,2,3,4" \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=500 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
done | ||
|
||
# ----Cocitation datasets---- | ||
datasets=( 'cocitation_cora' 'cocitation_citeseer' 'cocitation_pubmed' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
model=hypergraph/allsettransformer \ | ||
model.feature_encoder.out_channels="32,64,128" \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.n_layers="1,2" \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=25 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# ----Graph regression dataset---- | ||
# Train on ZINC dataset | ||
python train.py \ | ||
dataset=ZINC \ | ||
seed=42,3,5,23,150 \ | ||
model=hypergraph/allsettransformer \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.optimizer.weight_decay=0 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=2,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
dataset.parameters.data_seed=0 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
callbacks.early_stopping.min_delta=0.005 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
|
||
# ----TU graph datasets---- | ||
# MUTAG have very few samples, so we use a smaller batch size | ||
# Train on MUTAG dataset | ||
python train.py \ | ||
dataset=MUTAG \ | ||
model=hypergraph/allsettransformer \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=32,64 \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
callbacks.early_stopping.patience=25 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# Train rest of the TU graph datasets | ||
datasets=( 'PROTEINS_TU' 'NCI1' 'NCI109' 'REDDIT-BINARY' 'IMDB-BINARY' 'IMDB-MULTI' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=hypergraph/allsettransformer \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
--multirun | ||
done | ||
|
||
# ----Heterophilic datasets---- | ||
|
||
datasets=( roman_empire amazon_ratings tolokers minesweeper ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=hypergraph/allsettransformer \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.n_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,135 @@ | ||
# Description: Main experiment script for GCN model. | ||
# ----Node regression datasets: US County Demographics---- | ||
task_variables=( 'Election' 'MedianIncome' 'MigraRate' 'BirthRate' 'DeathRate' 'BachelorRate' 'UnemploymentRate' ) | ||
|
||
for task_variable in ${task_variables[*]} | ||
do | ||
python train.py \ | ||
dataset=us_country_demos \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
dataset.parameters.task_variable=$task_variable \ | ||
model=hypergraph/edgnn \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.All_num_layers=1,2,3,4 \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=500 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
done | ||
|
||
# ----Cocitation datasets---- | ||
datasets=( 'cocitation_cora' 'cocitation_citeseer' 'cocitation_pubmed' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
dataset.parameters.data_seed=0,3,5,7,9 \ | ||
model=hypergraph/edgnn \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
model.backbone.All_num_layers="1,2" \ | ||
model.optimizer.lr="0.01,0.001" \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=25 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done | ||
|
||
# ----Graph regression dataset---- | ||
# Train on ZINC dataset | ||
python train.py \ | ||
dataset=ZINC \ | ||
seed=42,3,5,23,150 \ | ||
model=hypergraph/edgnn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.optimizer.weight_decay=0 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.All_num_layers=2,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
dataset.transforms.one_hot_node_degree_features.degrees_fields=x \ | ||
dataset.parameters.data_seed=0 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
callbacks.early_stopping.min_delta=0.005 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# ----TU graph datasets---- | ||
# MUTAG have very few samples, so we use a smaller batch size | ||
# Train on MUTAG dataset | ||
python train.py \ | ||
dataset=MUTAG \ | ||
model=hypergraph/edgnn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.All_num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=32,64 \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
callbacks.early_stopping.patience=25 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
|
||
# Train rest of the TU graph datasets | ||
datasets=( 'PROTEINS_TU' 'NCI1' 'NCI109' 'REDDIT-BINARY' 'IMDB-BINARY' 'IMDB-MULTI' ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=hypergraph/edgnn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.All_num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
trainer.max_epochs=500 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=5 \ | ||
callbacks.early_stopping.patience=10 \ | ||
--multirun | ||
done | ||
|
||
# ----Heterophilic datasets---- | ||
|
||
datasets=( roman_empire amazon_ratings tolokers minesweeper ) | ||
|
||
for dataset in ${datasets[*]} | ||
do | ||
python train.py \ | ||
dataset=$dataset \ | ||
model=hypergraph/edgnn \ | ||
model.optimizer.lr=0.01,0.001 \ | ||
model.feature_encoder.out_channels=32,64,128 \ | ||
model.backbone.All_num_layers=1,2,3,4 \ | ||
model.feature_encoder.proj_dropout=0.25,0.5 \ | ||
dataset.parameters.data_seed=0,3,5 \ | ||
dataset.parameters.batch_size=128,256 \ | ||
logger.wandb.project=TopoBenchmarkX_Hypergraph \ | ||
trainer.max_epochs=1000 \ | ||
trainer.min_epochs=50 \ | ||
trainer.check_val_every_n_epoch=1 \ | ||
callbacks.early_stopping.patience=50 \ | ||
tags="[MainExperiment]" \ | ||
--multirun | ||
done |
Oops, something went wrong.