Better error handling
Fix axis normalisation