MCPcopy Create free account

hub / github.com/Graph-and-Geometric-Learning/hyperbolic-transformer / functions

Functions650 in github.com/Graph-and-Geometric-Learning/hyperbolic-transformer

↓ 35 callersMethodreset_parameters
(self)
large/gnns.py:53
↓ 35 callersMethodreset_parameters
(self)
medium/gnns.py:57
↓ 19 callersMethod__init__
(self, in_channels, hidden_channels, out_channels, num_layers, dropout=.5)
medium/gnns.py:39
↓ 18 callersMethod__init__
(self, in_channels, hidden_channels, out_channels, num_layers, dropout=.5)
large/gnns.py:35
↓ 9 callersFunction_inner
(u, v, keepdim: bool = False, dim: int = -1)
large/manifolds/lorentz_math.py:37
↓ 9 callersFunction_inner
(u, v, keepdim: bool = False, dim: int = -1)
medium/manifolds/lorentz_math.py:39
↓ 9 callersFunction_inner
(u, v, keepdim: bool = False, dim: int = -1)
Hypformer/manifolds/lorentz_math.py:39
↓ 9 callersMethodget_idx_split
train_prop: The proportion of dataset for train split. Between 0 and 1. valid_prop: The proportion of dataset for validation split. B
large/dataset.py:58
↓ 7 callersFunction_inner0
(v, k: torch.Tensor, keepdim: bool = False, dim: int = -1)
large/manifolds/lorentz_math.py:70
↓ 7 callersMethodmid_point
Compute the midpoint of points on the Lorentz manifold. Parameters ---------- x : torch.Tensor Points on
medium/manifolds/lorentz.py:506
↓ 6 callersFunction_norm
(u, keepdim: bool = False, dim: int = -1)
large/manifolds/lorentz_math.py:280
↓ 6 callersFunction_norm
(u, keepdim: bool = False, dim: int = -1)
medium/manifolds/lorentz_math.py:286
↓ 6 callersFunction_norm
(u, keepdim: bool = False, dim: int = -1)
Hypformer/manifolds/lorentz_math.py:286
↓ 6 callersMethodmid_point
Compute the midpoint of points on the Lorentz manifold. Parameters ---------- x : torch.Tensor Points on
large/manifolds/lorentz.py:537
↓ 5 callersMethod__init__
Initializes the HypCLS class with the given parameters. Parameters: - `manifold` (Manifold): The manifold object.
large/manifolds/layer.py:169
↓ 5 callersMethod__init__
(self, manifold, in_channels, out_channels, bias=True)
medium/manifolds/hyp_layer.py:128
↓ 5 callersMethod__init__
(self, manifold, in_channels, out_channels, bias=True)
Hypformer/manifolds/hyp_layer.py:122
↓ 5 callersMethod__init__
Initializes the HypCLS class with the given parameters. Parameters: - `manifold` (Manifold): The manifold object.
Hypformer/manifolds/layer.py:169
↓ 5 callersFunction_dist0
(x, k: torch.Tensor, keepdim: bool = False, dim: int = -1)
medium/manifolds/lorentz_math.py:136
↓ 5 callersFunction_dist0
(x, k: torch.Tensor, keepdim: bool = False, dim: int = -1)
Hypformer/manifolds/lorentz_math.py:136
↓ 5 callersFunctionclamp
(x: torch.Tensor, min: float = float("-inf"), max: float = float("+inf"))
large/manifolds/utils.py:237
↓ 5 callersFunctionclamp
(x: torch.Tensor, min: float = float("-inf"), max: float = float("+inf"))
medium/manifolds/manifold_utils.py:238
↓ 5 callersFunctionclamp
(x: torch.Tensor, min: float = float("-inf"), max: float = float("+inf"))
Hypformer/manifolds/utils.py:237
↓ 5 callersMethodexpmap0
Perform the exponential map from the origin. Parameters: u (torch.Tensor): Tangent vector. project (bool): I
Hypformer/manifolds/lorentz.py:253
↓ 5 callersMethodmid_point
Compute the midpoint of points on the manifold. Parameters: x (torch.Tensor): Points on the manifold. w (tor
Hypformer/manifolds/lorentz.py:500
↓ 5 callersMethodnorm
Compute the norm of a tangent vector. Parameters: u (torch.Tensor): Tangent vector. keepdim (bool): If True,
Hypformer/manifolds/lorentz.py:163
↓ 4 callersFunction_inner0
(v, k: torch.Tensor, keepdim: bool = False, dim: int = -1)
medium/manifolds/lorentz_math.py:72
↓ 4 callersFunction_inner0
(v, k: torch.Tensor, keepdim: bool = False, dim: int = -1)
Hypformer/manifolds/lorentz_math.py:72
↓ 4 callersFunctioneval_acc
true: (n, 1) pred: (n, c)
large/eval.py:140
↓ 4 callersMethodnorm
Compute the norm of a tangent vector. Parameters: u (torch.Tensor): Tangent vector. keepdim (bool): If True,
large/manifolds/lorentz.py:183
↓ 4 callersMethodnorm
Compute the norm of a tangent vector. Parameters: u (torch.Tensor): Tangent vector. keepdim (bool): If True,
medium/manifolds/lorentz.py:146
↓ 4 callersMethodprint_statistics
(self, run=None, mode='max_acc')
large/logger.py:39
↓ 3 callersFunction_dist
(x, y, k: torch.Tensor, keepdim: bool = False, dim: int = -1)
medium/manifolds/lorentz_math.py:107
↓ 3 callersFunction_dist
(x, y, k: torch.Tensor, keepdim: bool = False, dim: int = -1)
Hypformer/manifolds/lorentz_math.py:107
↓ 3 callersFunction_dist0
(x, k: torch.Tensor, keepdim: bool = False, dim: int = -1)
large/manifolds/lorentz_math.py:134
↓ 3 callersFunction_logmap
(x, y, k, dim: int = -1)
medium/manifolds/lorentz_math.py:398
↓ 3 callersFunction_logmap
(x, y, k, dim: int = -1)
Hypformer/manifolds/lorentz_math.py:398
↓ 3 callersFunction_logmap0
(y, k, dim: int = -1)
medium/manifolds/lorentz_math.py:425
↓ 3 callersFunction_logmap0
(y, k, dim: int = -1)
Hypformer/manifolds/lorentz_math.py:425
↓ 3 callersFunction_logmap0back
(x, k, dim: int = -1)
medium/manifolds/lorentz_math.py:454
↓ 3 callersFunction_logmap0back
(x, k, dim: int = -1)
Hypformer/manifolds/lorentz_math.py:454
↓ 3 callersFunctionarcosh
(x: torch.Tensor)
large/manifolds/lorentz_math.py:7
↓ 3 callersFunctionarcosh
Computes the inverse hyperbolic cosine safely.
medium/manifolds/lorentz_math.py:8
↓ 3 callersFunctionarcosh
Computes the inverse hyperbolic cosine safely.
Hypformer/manifolds/lorentz_math.py:8
↓ 3 callersMethodexpmap0
Perform the exponential map from the origin. Parameters: u (torch.Tensor): Tangent vector. project (bool): I
large/manifolds/lorentz.py:273
↓ 3 callersMethodexpmap0
Perform the exponential map from the origin. Parameters: u (torch.Tensor): Tangent vector. project (bool): I
medium/manifolds/lorentz.py:236
↓ 3 callersMethodinner
Compute the inner product of two tangent vectors at a point. Parameters: x (torch.Tensor): Point on the manifold.
large/manifolds/lorentz.py:331
↓ 3 callersMethodinner
Compute the inner product of two tangent vectors at a point. Parameters: x (torch.Tensor): Point on the manifold.
Hypformer/manifolds/lorentz.py:311
↓ 3 callersMethodlogmap0
Perform the logarithmic map from the origin. Parameters: y (torch.Tensor): Point on the manifold. dim (int):
large/manifolds/lorentz.py:305
↓ 3 callersMethodlogmap0
Perform the logarithmic map from the origin. Parameters: y (torch.Tensor): Point on the manifold. dim (int):
medium/manifolds/lorentz.py:268
↓ 3 callersFunctionrand_train_test_idx
randomly splits label into train/valid/test splits
large/data_utils.py:13
↓ 3 callersMethodsave
(self, params, results, filename)
large/logger.py:144
↓ 3 callersFunctionsqrt
(x: torch.Tensor)
medium/manifolds/manifold_utils.py:218
↓ 2 callersMethod__init__
(self, manifold_in, manifold_hidden, manifold_out, in_channels, hidden_channels, num_layers=2, num_heads=1,
large/hypformer.py:180
↓ 2 callersMethod__init__
(self, manifold_in, manifold_hidden, manifold_out, in_channels, hidden_channels, args=None)
medium/hypformer.py:176
↓ 2 callersMethod__init__
(self, manifold_in, manifold_hidden, manifold_out, in_channels, hidden_channels, num_layers=2, num_heads=1,
Hypformer/hypformer.py:154
↓ 2 callersFunction_dist
(x, y, k: torch.Tensor, keepdim: bool = False, dim: int = -1)
large/manifolds/lorentz_math.py:105
↓ 2 callersMethodadd_result
(self, run, result)
large/logger.py:18
↓ 2 callersMethodbackward
(ctx: Any, grad_output: torch.Tensor)
large/manifolds/utils.py:256
↓ 2 callersMethodcinner
(self, x, y)
large/manifolds/layer.py:191
↓ 2 callersMethodcinner
(self, x, y)
Hypformer/manifolds/layer.py:191
↓ 2 callersFunctioncompute_degrees
(edge_index, num_nodes)
large/data_utils.py:304
↓ 2 callersFunctionevaluate_large
(model, dataset, split_idx, eval_func, criterion, args, degrees, threshold, device="cpu", result=None)
large/eval.py:45
↓ 2 callersFunctioneven_quantile_labels
partitions vals into nclasses by a quantile based split, where the first class is less than the 1/nclasses quantile, second class is less tha
large/data_utils.py:79
↓ 2 callersMethodexpmap
Perform the exponential map to move from a point in the tangent space to the manifold. Parameters: x (torch.Tensor): Poi
large/manifolds/lorentz.py:251
↓ 2 callersMethodexpmap
Perform the exponential map to move from a point in the tangent space to the manifold. Parameters: x (torch.Tensor): Poi
medium/manifolds/lorentz.py:214
↓ 2 callersMethodexpmap
Perform the exponential map to move from a point in the tangent space to the manifold. Parameters: x (torch.Tensor): Poi
Hypformer/manifolds/lorentz.py:231
↓ 2 callersMethodfp
(x, p=2)
large/hypformer.py:81
↓ 2 callersMethodfp
(x, p=2)
medium/hypformer.py:79
↓ 2 callersMethodfp
(x, p=2)
Hypformer/hypformer.py:42
↓ 2 callersMethodfull_attention
(self, qs, ks, vs, output_attn=False)
large/hypformer.py:61
↓ 2 callersMethodfull_attention
(self, qs, ks, vs, output_attn=False)
medium/hypformer.py:59
↓ 2 callersMethodfull_attention
(self, qs, ks, vs, output_attn=False)
Hypformer/hypformer.py:47
↓ 2 callersMethodget_attentions
(self, x_input)
medium/hypformer.py:248
↓ 2 callersMethodinner
Compute the inner product of two tangent vectors at a point. Parameters: x (torch.Tensor): Point on the manifold.
medium/manifolds/lorentz.py:294
↓ 2 callersMethodlinear_focus_attention
(self, hyp_qs, hyp_ks, hyp_vs, output_attn=False)
large/hypformer.py:86
↓ 2 callersMethodlinear_focus_attention
(self, hyp_qs, hyp_ks, hyp_vs, output_attn=False)
medium/hypformer.py:84
↓ 2 callersMethodlinear_focus_attention
(self, hyp_qs, hyp_ks, hyp_vs, output_attn=False)
Hypformer/hypformer.py:66
↓ 2 callersFunctionload_dataset
Loader for NCDataset Returns NCDataset
large/dataset.py:89
↓ 2 callersFunctionload_fixed_splits
(data_dir, dataset, name, protocol)
large/data_utils.py:39
↓ 2 callersFunctionload_papers100M
(data_dir)
large/dataset.py:301
↓ 2 callersMethodlogmap0
Perform the logarithmic map from the origin. Parameters: y (torch.Tensor): Point on the manifold. dim (int):
Hypformer/manifolds/lorentz.py:285
↓ 2 callersFunctionnormalize_feat
Row-normalize np or sparse matrix.
medium/data_utils.py:63
↓ 2 callersFunctionpapers100M_sub
(data_dir)
large/dataset.py:628
↓ 2 callersFunctionparse_method
(args, c, d, device)
large/parse.py:4
↓ 2 callersFunctionparser_add_main_args
(parser)
large/parse.py:15
↓ 2 callersMethodprint_statistics
(self, run=None, mode='max_acc')
medium/logger.py:31
↓ 2 callersMethodrandom_normal
Create a random point on the manifold, induced by a normal distribution on the tangent space of zero. Parameters: size:
Hypformer/manifolds/lorentz.py:455
↓ 2 callersMethodreset_parameters
Reset layer parameters.
large/manifolds/layer.py:149
↓ 2 callersMethodreset_parameters
(self)
medium/manifolds/hyp_layer.py:109
↓ 2 callersMethodreset_parameters
(self)
Hypformer/manifolds/hyp_layer.py:105
↓ 2 callersMethodreset_parameters
Reset layer parameters.
Hypformer/manifolds/layer.py:149
↓ 2 callersMethodsave
(self, params, results, filename)
medium/logger.py:87
↓ 2 callersFunctionsplit_data
(labels, val_prop, test_prop, seed=1234)
medium/data_utils.py:168
↓ 2 callersFunctionsqrt
(x: torch.Tensor)
large/manifolds/utils.py:217
↓ 2 callersMethodstep
Performs a single optimization step.
large/manifolds/layer.py:255
↓ 2 callersMethodzero_grad
Sets the gradients of all optimized tensors to zero.
large/manifolds/layer.py:260
↓ 1 callersFunction_egrad2rgrad
(x, grad, k, dim: int = -1)
large/manifolds/lorentz_math.py:485
↓ 1 callersFunction_egrad2rgrad
(x, grad, k, dim: int = -1)
medium/manifolds/lorentz_math.py:491
↓ 1 callersFunction_egrad2rgrad
(x, grad, k, dim: int = -1)
Hypformer/manifolds/lorentz_math.py:491
next →1–100 of 650, ranked by callers