add logging
added utility evaluation code
pruning support for matrices, move sampling to matrix
reinstate shuffling in SGD
update example with the recent changes