pyjuice.nodes.InputNodes
- class pyjuice.nodes.InputNodes(num_node_blocks: int, scope: Sequence | BitSet, dist: Distribution, params: torch.Tensor | None = None, block_size: int = 0, _no_set_meta_params: bool = False, **kwargs)
A class representing vectors of input nodes. It is created by
pyjuice.inputs
.- Parameters:
- __init__(num_node_blocks: int, scope: Sequence | BitSet, dist: Distribution, params: torch.Tensor | None = None, block_size: int = 0, _no_set_meta_params: bool = False, **kwargs) None
Methods
duplicate
([scope, tie_params])Create a duplication of the current node with the same specification (i.e., number of nodes, block size, distribution).
get_params
()Get the input node parameters.
init_parameters
([perturbation, recursive, ...])Randomly initialize node parameters.
num_parameters
([count_input_params, recursive])set_meta_params
(**kwargs)Set the meta-parameters such as the mask of input nodes with the MaskedCategorical distribution.
set_params
(params[, normalize])Set the input node parameters.