Dragon API Dragon v0.3.0 Python Sigmoid¶ class dragon.vm.torch.nn.Sigmoid(inplace=False)[source]¶ Apply the sigmoid function. The Sigmoid function is defined as: \[\text{Sigmoid}(x) = \frac{1}{1 + \exp(-x)} \] Examples: m = torch.nn.Sigmoid() x = torch.randn(2, 3) y = m(x) See also torch.nn.functional.sigmoid(…) __init__¶ Sigmoid.__init__(inplace=False)[source]¶ Create a Sigmoid module. Parameters: inplace (bool, optional, default=False) – Whether to do the operation in-place.