fixed log and added pickle
fixed ini matrix row