Beispiel #1
0
def default_parameter(dataset):
    args = {
        "hidden_size": 128,
        "num_shuffle": 5,
        "cpu": True,
        "enhance": None,
        "save_dir": ".",
        "seed": [0, 1, 2],
        "step": 5,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #2
0
def build_default_args_for_unsupervised_node_classification(dataset):
    args = {
        "hidden_size": 128,
        "num_shuffle": 5,
        "cpu": True,
        "enhance": None,
        "save_dir": ".",
        "seed": [0, 1, 2],
        "task": "unsupervised_node_classification",
        "model": "spectral",
        "dataset": dataset,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #3
0
def default_parameter():
    args = {
        "hidden_size": 128,
        "num_shuffle": 5,
        "cpu": True,
        "seed": [0, 1, 2],
        "walk_length": 80,
        "walk_num": 20,
        "negative": 5,
        "batch_size": 1000,
        "alpha": 0.025,
        "order": 3,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #4
0
def default_parameter():
    args = {
        "hidden_size": 128,
        "num_shuffle": 5,
        "cpu": True,
        "seed": [0, 1, 2],
        "walk_length": 80,
        "walk_num": 40,
        "window_size": 5,
        "worker": 10,
        "iteration": 10,
        "p": 1.0,
        "q": 1.0,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #5
0
def build_default_args_for_unsupervised_node_classification(dataset):
    args = {
        "hidden_size": 128,
        "num_shuffle": 5,
        "cpu": True,
        "enhance": None,
        "save_dir": ".",
        "seed": [0, 1, 2],
        "window_size": 5,
        "rank": 256,
        "negative": 1,
        "is_large": False,
        "task": "unsupervised_node_classification",
        "model": "netmf",
        "dataset": dataset,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #6
0
def build_default_args_for_multiplex_node_classification(dataset):
    args = {
        "hidden_size": 128,
        "cpu": True,
        "enhance": None,
        "save_dir": ".",
        "seed": [0, 1, 2],
        "walk_length": 80,
        "walk_num": 40,
        "negative": 5,
        "batch_size": 1000,
        "alpha": 0.025,
        "task": "multiplex_node_classification",
        "model": "pte",
        "dataset": dataset,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #7
0
def build_default_args_for_multiplex_node_classification(dataset):
    args = {
        "hidden_size": 128,
        "cpu": True,
        "enhance": None,
        "save_dir": ".",
        "seed": [0, 1, 2],
        "walk_length": 80,
        "walk_num": 40,
        "window_size": 5,
        "worker": 10,
        "iteration": 10,
        "schema": "No",
        "task": "multiplex_node_classification",
        "model": "metapath2vec",
        "dataset": dataset,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #8
0
def build_default_args_for_unsupervised_node_classification(dataset):
    args = {
        "hidden_size": 128,
        "num_shuffle": 5,
        "cpu": True,
        "enhance": None,
        "save_dir": ".",
        "seed": [0, 1, 2],
        "walk_length": 80,
        "walk_num": 40,
        "window_size": 5,
        "worker": 10,
        "iteration": 10,
        "task": "unsupervised_node_classification",
        "model": "deepwalk",
        "dataset": dataset,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #9
0
def build_default_args_for_unsupervised_node_classification(dataset):
    args = {
        "hidden_size": 128,
        "num_shuffle": 5,
        "cpu": True,
        "enhance": None,
        "save_dir": ".",
        "seed": [0, 1, 2],
        "walk_length": 80,
        "walk_num": 20,
        "negative": 5,
        "batch_size": 1000,
        "alpha": 0.025,
        "order": 3,
        "task": "unsupervised_node_classification",
        "model": "line",
        "dataset": dataset,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #10
0
def build_default_args_for_unsupervised_node_classification(dataset):
    args = {
        "hidden_size": 128,
        "num_shuffle": 5,
        "cpu": True,
        "enhance": None,
        "save_dir": ".",
        "seed": [0, 1, 2],
        "lr": 0.001,
        "max_epoch": 500,
        "hidden_size1": 1000,
        "hidden_size2": 128,
        "noise": 0.2,
        "alpha": 0.1,
        "step": 10,
        "task": "unsupervised_node_classification",
        "model": "dngr",
        "dataset": dataset,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #11
0
def build_default_args_for_multiplex_node_classification(dataset):
    cpu = not torch.cuda.is_available()
    args = {
        "hidden_size": 128,
        "cpu": cpu,
        "enhance": None,
        "save_dir": ".",
        "seed": [0, 1, 2],
        "lr": 0.025,
        "walk_length": 80,
        "walk_num": 40,
        "batch_size": 1000,
        "hop": 2,
        "negative": 5,
        "epochs": 1,
        "task": "multiplex_node_classification",
        "model": "hin2vec",
        "dataset": dataset,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #12
0
def build_default_args_for_node_classification(dataset,
                                               missing_rate=0,
                                               num_layers=40):
    cpu = not torch.cuda.is_available()
    args = {
        "lr": 0.005,
        "weight_decay": 5e-4,
        "max_epoch": 1000,
        "patience": 1000,
        "cpu": cpu,
        "device_id": [0],
        "seed": [0, 1, 2, 3, 4],
        "missing_rate": missing_rate,
        "norm_mode": "PN",
        "norm_scale": 10,
        "dropout": 0.6,
        "num_layers": num_layers,
        "task": "node_classification",
        "model": "sgcpn",
        "dataset": dataset,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)
Beispiel #13
0
def build_default_args_for_multiplex_link_prediction(dataset):
    cpu = not torch.cuda.is_available()
    args = {
        "hidden_size": 200,
        "cpu": cpu,
        "eval_type": "all",
        "seed": [0, 1, 2],
        "walk_length": 10,
        "walk_num": 10,
        "window_size": 5,
        "worker": 10,
        "epoch": 20,
        "batch_size": 256,
        "edge_dim": 10,
        "att_dim": 20,
        "negative_samples": 5,
        "neighbor_samples": 10,
        "schema": None,
        "task": "multiplex_link_prediction",
        "model": "gatne",
        "dataset": dataset,
    }
    args = get_extra_args(args)
    return build_args_from_dict(args)