Commit Graph

16 Commits

Author SHA1 Message Date
lyken 9c9b832519
core/ndstrides: implement general ndarray matmul 2024-08-21 11:34:22 +08:00
lyken 6ba3dcf62e
core/ndstrides: implement np_transpose() (no axes argument) 2024-08-21 11:33:20 +08:00
lyken 137cc0c5f2
core/ndstrides: implement np_reshape() 2024-08-21 11:33:20 +08:00
lyken dc513d64b3
core/ndstrides: implement np_array()
It also checks for inconsistent dimensions if the input is a list.
e.g., rejecting `[[1.0, 2.0], [3.0]]`. Previously it was a todo of
`np_array()`.
2024-08-21 11:33:20 +08:00
lyken 35cb482f02
core/irrt: add List
Needed for implementing np_array()
2024-08-21 11:33:20 +08:00
lyken 1aa3f468ad
core/ndstrides: implement general ndarray indexing
`...`, `none` are now also supported.
2024-08-21 11:31:50 +08:00
lyken ccc6ed9748
core/irrt: rename NDIndex to NDIndexInt
The name `NDIndex` is used in later commits.
2024-08-21 11:27:03 +08:00
lyken afb08f61cf
core/irrt: add Slice and ResolvedSlice
Needed for implementing general ndarray indexing
2024-08-21 11:27:03 +08:00
lyken 751a319be9
core/ndstrides: add ndarray iterator 2024-08-21 11:22:43 +08:00
lyken f6b80fc40a
core/ndstrides: add basic ndarray utilities 2024-08-21 11:22:43 +08:00
lyken 20db7298aa
core/ndstrides: define ndarray with strides 2024-08-21 11:22:43 +08:00
lyken efefa13b7e
core/irrt/exceptions: add debug utils with exceptions 2024-08-21 11:22:43 +08:00
lyken 59ddf084d2
core/irrt/exceptions: allow irrt to raise exceptions 2024-08-21 11:22:43 +08:00
lyken 84653279bb
core/irrt: split irrt.cpp into headers 2024-08-21 11:22:43 +08:00
lyken 40568d2e1b
core/irrt: reformat 2024-08-21 11:22:43 +08:00
lyken c9c5c83e6c
core/irrt: comment build.rs & move irrt to its own dir
To prepare for future IRRT implementations, and to also make cargo
only have to watch a single directory.
2024-08-21 11:22:43 +08:00