hasktorch-gradually-typed-0.2.0.0: experimental project for hasktorch
Safe HaskellSafe-Inferred
LanguageHaskell2010

Torch.GraduallyTyped.Index.Type

Documentation

data Index (index :: Type) where Source #

Constructors

UncheckedIndex :: forall index. Index index 
Index :: forall index. index -> Index index 
NegativeIndex :: forall index. index -> Index index 

Instances

Instances details
Show index => Show (Index index) Source # 
Instance details

Defined in Torch.GraduallyTyped.Index.Type

Methods

showsPrec :: Int -> Index index -> ShowS Source #

show :: Index index -> String Source #

showList :: [Index index] -> ShowS Source #

SingKind (Index Nat) Source # 
Instance details

Defined in Torch.GraduallyTyped.Index.Type

Associated Types

type Demote (Index Nat) = (r :: Type) Source #

Methods

fromSing :: forall (a :: Index Nat). Sing a -> Demote (Index Nat) Source #

toSing :: Demote (Index Nat) -> SomeSing (Index Nat) Source #

SingKind (Indices [IndexType (Index Nat)]) Source # 
Instance details

Defined in Torch.GraduallyTyped.Tensor.Indexing

Associated Types

type Demote (Indices [IndexType (Index Nat)]) = (r :: Type) Source #

KnownNat index => SingI ('Index index :: Index Nat) Source # 
Instance details

Defined in Torch.GraduallyTyped.Index.Type

Methods

sing :: Sing ('Index index) Source #

KnownNat index => SingI ('NegativeIndex index :: Index Nat) Source # 
Instance details

Defined in Torch.GraduallyTyped.Index.Type

Methods

sing :: Sing ('NegativeIndex index) Source #

SingI indexTypes => SingI ('Indices indexTypes :: Indices [IndexType (Index Nat)]) Source # 
Instance details

Defined in Torch.GraduallyTyped.Tensor.Indexing

Methods

sing :: Sing ('Indices indexTypes) Source #

type Demote (Index Nat) Source # 
Instance details

Defined in Torch.GraduallyTyped.Index.Type

type Demote (Indices [IndexType (Index Nat)]) Source # 
Instance details

Defined in Torch.GraduallyTyped.Tensor.Indexing

type Sing Source # 
Instance details

Defined in Torch.GraduallyTyped.Index.Type

type Sing = SIndex
type Sing Source # 
Instance details

Defined in Torch.GraduallyTyped.Tensor.Indexing

type Sing = SIndices

data SIndex (index :: Index Nat) where Source #

Constructors

SUncheckedIndex :: Integer -> SIndex 'UncheckedIndex 
SIndex :: forall index. KnownNat index => SIndex ('Index index) 
SNegativeIndex :: forall index. KnownNat index => SIndex ('NegativeIndex index) 

Instances

Instances details
Show (SIndex index) Source # 
Instance details

Defined in Torch.GraduallyTyped.Index.Type

Methods

showsPrec :: Int -> SIndex index -> ShowS Source #

show :: SIndex index -> String Source #

showList :: [SIndex index] -> ShowS Source #

type family IndexF (index :: Index Nat) :: Nat where ... Source #

Equations

IndexF ('Index index) = index 
IndexF ('NegativeIndex index) = index