hasktorch-0.2.0.0: Functional differentiable programming in Haskell
Safe HaskellSafe-Inferred
LanguageHaskell2010

Torch.Typed.Vision

Documentation

data MNIST (m :: Type -> Type) (device :: (DeviceType, Nat)) (batchSize :: Nat) Source #

Constructors

MNIST 

Fields

Instances

Instances details
(KnownNat batchSize, KnownDevice device, Applicative m) => Dataset (m :: Type -> Type) (MNIST m device batchSize) Int ((Tensor device 'Float '[batchSize, 784], Tensor device 'Int64 '[batchSize]) :: Type) Source # 
Instance details

Defined in Torch.Typed.Vision

Methods

getItem :: MNIST m device batchSize -> Int -> m (Tensor device 'Float '[batchSize, 784], Tensor device 'Int64 '[batchSize]) Source #

keys :: MNIST m device batchSize -> Set Int Source #

data MnistData Source #

Constructors

MnistData 

type Rows = 28 Source #

type Cols = 28 Source #

type ClassDim = 10 Source #

getLabels :: forall n. KnownNat n => MnistData -> [Int] -> CPUTensor 'Int64 '[n] Source #

getImages' :: forall n. KnownNat n => MnistData -> [Int] -> CPUTensor 'Float '[n, DataDim] Source #

getImages :: forall n. KnownNat n => MnistData -> [Int] -> CPUTensor 'Float '[n, DataDim] Source #