Speed up memory views in local_binary_pattern