You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This discussion is for random tensor and tensorfs design issues.
tensorfs
Working through the basic tensor access API.
The basic workhorse function is:
tsr := tensorfs.Value[float64](dir, "filename", 5, 5)
Key features:
avoid tricky issues with timing of creation / init vs. access by using one function for both, with type, name, and optional shape sizes.
don't duplicate the tensor access / setting api -- just get the tensor and call tensor methods on it.
Get prefix is an anti-pattern.
also, as usual, want to make things as compact as possible: provide functions for high-frequency basic types.
one annoying challenge is avoiding the String method for string tensors -- taken by Stringer. tensor.StringValue is one example.
Added type-specific accessors, which is significantly more compact in real code:
Float64, Float32, Int, StringValue functions on Node
Another question: should table and tensorfs have the same api? A column is effectively the same as a tensorfs Node. Currently, table just has dt.Column("name") that gives you the tensor with row indexes -- don't want / need to be passing create api around here, right?
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
This discussion is for random tensor and tensorfs design issues.
tensorfs
Working through the basic tensor access API.
The basic workhorse function is:
Key features:
String
method for string tensors -- taken by Stringer.tensor.StringValue
is one example.Added type-specific accessors, which is significantly more compact in real code:
Float64
,Float32
,Int
,StringValue
functions onNode
Another question: should table and tensorfs have the same api? A column is effectively the same as a tensorfs Node. Currently, table just has
dt.Column("name")
that gives you the tensor with row indexes -- don't want / need to be passing create api around here, right?Beta Was this translation helpful? Give feedback.
All reactions