agedi.diffusion.distributions.constant ====================================== .. py:module:: agedi.diffusion.distributions.constant Classes ------- .. autoapisummary:: agedi.diffusion.distributions.constant.Constant Module Contents --------------- .. py:class:: Constant(value: float = 0, key: str = 'x', dtype: Type = torch.int64, **kwargs) Bases: :py:obj:`agedi.diffusion.distributions.Distribution` Constant Integer Distribution .. py:attribute:: value :value: 0 .. py:attribute:: dtype .. py:method:: get_hparams() -> Dict Return hyperparameters for this distribution. .. py:method:: _setup(batch: agedi.data.AtomsGraph) -> None Prepare the distribution for sampling from *batch*. Sets ``self.shape`` based on the total number of atoms in the batch. :param batch: Batch of atomistic data. :type batch: AtomsGraph .. py:method:: _sample(shape: Optional[torch.Size] = None) -> torch.Tensor Sample from the integer distribution :param mu: Mean of the distribution :type mu: torch.Tensor :param sigma: Standard deviation of the distribution :type sigma: torch.Tensor :returns: Sampled tensor :rtype: torch.Tensor