Copyright | (c) Sam Stites 2017 |
---|---|
License | BSD3 |
Maintainer | sam@stites.io |
Stability | experimental |
Portability | non-portable |
Safe Haskell | None |
Language | Haskell2010 |
Synopsis
- random :: Dimensions d => IO (Tensor d)
- clampedRandom :: Dimensions d => Integer -> Integer -> IO (Tensor d)
- cappedRandom :: Dimensions d => Integer -> IO (Tensor d)
- bernoulli :: Dimensions d => HsAccReal -> IO (Tensor d)
- bernoulli_DoubleTensor :: Dimensions d => Tensor d -> IO (Tensor d)
- geometric :: Dimensions d => HsAccReal -> IO (Tensor d)
- uniform :: Dimensions d => Ord2Tuple HsAccReal -> IO (Tensor d)
- normal :: Dimensions d => HsAccReal -> Positive HsAccReal -> IO (Tensor d)
- normal_means :: Dimensions d => Tensor d -> Positive HsAccReal -> IO (Tensor d)
- normal_stddevs :: Dimensions d => HsAccReal -> Tensor d -> IO (Tensor d)
- normal_means_stddevs :: Dimensions d => Tensor d -> Tensor d -> IO (Tensor d)
- logNormal :: Dimensions d => HsAccReal -> Positive HsAccReal -> IO (Tensor d)
- exponential :: Dimensions d => HsAccReal -> IO (Tensor d)
- cauchy :: Dimensions d => HsAccReal -> HsAccReal -> IO (Tensor d)
- rand :: Dimensions d => LongStorage -> IO (Tensor d)
- randn :: Dimensions d => LongStorage -> IO (Tensor d)
- _multinomial :: LongTensor d1 -> Tensor d2 -> Int -> Int -> IO ()
- _multinomialAliasSetup :: Tensor d1 -> LongTensor d2 -> Tensor d3 -> IO ()
- _multinomialAliasDraw :: LongTensor d1 -> LongTensor d2 -> Tensor d3 -> IO ()
- data OpenUnit x
- openUnit :: (Ord x, Num x) => x -> Maybe (OpenUnit x)
- openUnitValue :: OpenUnit x -> x
- data ClosedUnit x
- closedUnit :: (Ord x, Num x) => x -> Maybe (ClosedUnit x)
- closedUnitValue :: ClosedUnit x -> x
- data Positive x
- positive :: (Ord x, Num x) => x -> Maybe (Positive x)
- positiveValue :: Positive x -> x
- data Ord2Tuple x
- ord2Tuple :: (Ord x, Num x) => (x, x) -> Maybe (Ord2Tuple x)
- ord2TupleValue :: Ord2Tuple x -> (x, x)
Documentation
clampedRandom :: Dimensions d => Integer -> Integer -> IO (Tensor d) Source #
Static call to clampedRandom
cappedRandom :: Dimensions d => Integer -> IO (Tensor d) Source #
Static call to cappedRandom
bernoulli_DoubleTensor :: Dimensions d => Tensor d -> IO (Tensor d) Source #
Static call to bernoulli_DoubleTensor
normal :: Dimensions d => HsAccReal -> Positive HsAccReal -> IO (Tensor d) Source #
Static call to normal
normal_means :: Dimensions d => Tensor d -> Positive HsAccReal -> IO (Tensor d) Source #
Static call to normal_means
normal_stddevs :: Dimensions d => HsAccReal -> Tensor d -> IO (Tensor d) Source #
Static call to normal_stddevs
normal_means_stddevs :: Dimensions d => Tensor d -> Tensor d -> IO (Tensor d) Source #
Static call to normal_means_stddevs
logNormal :: Dimensions d => HsAccReal -> Positive HsAccReal -> IO (Tensor d) Source #
Static call to logNormal
exponential :: Dimensions d => HsAccReal -> IO (Tensor d) Source #
Static call to exponential
_multinomial :: LongTensor d1 -> Tensor d2 -> Int -> Int -> IO () Source #
Static call to _multinomial
_multinomialAliasSetup :: Tensor d1 -> LongTensor d2 -> Tensor d3 -> IO () Source #
Static call to _multinomialAliasSetup
_multinomialAliasDraw :: LongTensor d1 -> LongTensor d2 -> Tensor d3 -> IO () Source #
Static call to _multinomialAliasDraw
Datatype to represent the open unit interval: 0 < x < 1
. Any OpenUnit
inhabitant
must satisfy being in the interval.
FIXME: replace with numhask.
Instances
Eq x => Eq (OpenUnit x) | |
Ord x => Ord (OpenUnit x) | |
Show x => Show (OpenUnit x) | |
openUnit :: (Ord x, Num x) => x -> Maybe (OpenUnit x) #
smart constructor to place a number in the open unit interval.
openUnitValue :: OpenUnit x -> x #
Get a value from the open unit interval.
data ClosedUnit x #
Datatype to represent the closed unit interval: 0 =< x =< 1
. Any ClosedUnit
inhabitant must satisfy being in the interval.
FIXME: replace with numhask.
Instances
Eq x => Eq (ClosedUnit x) | |
Defined in Torch.Types.Numeric (==) :: ClosedUnit x -> ClosedUnit x -> Bool # (/=) :: ClosedUnit x -> ClosedUnit x -> Bool # | |
Ord x => Ord (ClosedUnit x) | |
Defined in Torch.Types.Numeric compare :: ClosedUnit x -> ClosedUnit x -> Ordering # (<) :: ClosedUnit x -> ClosedUnit x -> Bool # (<=) :: ClosedUnit x -> ClosedUnit x -> Bool # (>) :: ClosedUnit x -> ClosedUnit x -> Bool # (>=) :: ClosedUnit x -> ClosedUnit x -> Bool # max :: ClosedUnit x -> ClosedUnit x -> ClosedUnit x # min :: ClosedUnit x -> ClosedUnit x -> ClosedUnit x # | |
Show x => Show (ClosedUnit x) | |
Defined in Torch.Types.Numeric showsPrec :: Int -> ClosedUnit x -> ShowS # show :: ClosedUnit x -> String # showList :: [ClosedUnit x] -> ShowS # |
closedUnit :: (Ord x, Num x) => x -> Maybe (ClosedUnit x) #
smart constructor to place a number in the closed unit interval.
closedUnitValue :: ClosedUnit x -> x #
Get a value from the closed unit interval.
Datatype to represent a generic positive number: 0 =< x
.
FIXME: replace with numhask.
Instances
Eq x => Eq (Positive x) | |
Ord x => Ord (Positive x) | |
Show x => Show (Positive x) | |
positive :: (Ord x, Num x) => x -> Maybe (Positive x) #
smart constructor to place a number in a positive bound.
positiveValue :: Positive x -> x #
Get a value from the positive bound.
Datatype to represent an ordered pair of numbers, (a, b)
, where a <= b
.
FIXME: replace with numhask.
ord2Tuple :: (Ord x, Num x) => (x, x) -> Maybe (Ord2Tuple x) #
smart constructor to place two values in an ordered tuple.
ord2TupleValue :: Ord2Tuple x -> (x, x) #
Get the values of an ordered tuple.