static public Tensor log_softmax(Tensor x, long dimension) { using (var l = nn.LogSoftmax(dimension)) { return(l.forward(x)); } }
/// <summary> /// Generates uniformly distributed random samples from the half-open interval [low, high[. /// </summary> /// <param name="low">Lower bound (inclusive)</param> /// <param name="high">Upper bound (exclusive)</param> /// <param name="generator">An optional random number generator object.</param> /// <returns></returns> public static Uniform Uniform(Tensor low, Tensor high, torch.Generator generator = null) { return(new Uniform(low, high, generator)); }