Ok, progress on the math front. *I think that people's code bases
should in general be portable now, with mostly some import renaming.
If that's not true, let me know what to add and I will add it.*
Test coverage is now at 44% of instructions and 28% of branches, with
242 unit tests. They hit almost everything besides Matrix operators at
least some. (On a related note, by removing Binary[Update]Op's
inheritance of Function2, I decreased the number of instructions in
the code base from ~300K to ~86K... Fun times.)
I've brought back all linear algebra routines.
I've reintroduced the axis-based reduction operations (sum, mean,
etc.) in a way that is nice and generic. Basically sum(Tensor, Axis)
looks for a CanCollapse[Tensor, Axis, AxisTensor, ...] that then
reduces the AxisTensor down to a single value.
For instance:
assert(sum(DenseMatrix((1.0,3.0),(2.0,4.0)), Axis._0) ===
DenseMatrix((3., 7.)))
assert(sum(DenseMatrix((1.0,3.0),(2.0,4.0)), Axis._1) ===
DenseVector(4., 6.))
assert(sum(Counter2((1,'a,1.0),(1, 'b, 3.0), (2, 'a, 2.0), (2, 'b,
4.0)), Axis._0) === Counter('a -> 3., 'b -> 7.))
assert(sum(Counter2((1,'a,1.0),(1, 'b, 3.0), (2, 'a, 2.0), (2, 'b,
4.0)), Axis._1) === Counter(1 -> 4., 2 -> 6.))
That's it.
-- David