code: def crude_mat2euler(M):
      """The simplest possible - ignoring atan2 instability"""
      r11, r12, r13, r21, r22, r23, r31, r32, r33 = M.flat
      return (
          math.atan2(-r12, r11),
          math.asin(r13),
          math.atan2(-r23, r33),
      )
  
file_path: nibabel/nibabel/tests/test_euler.py
imports: import math
  import numpy
  import pytest
  from numpy import pi
  from numpy.testing import assert_array_almost_equal, assert_array_equal
  from ..None import eulerangles
  from ..None import quaternions
label_desc: Use image node_id 10 for calling a global function with example usage: crude_mat2euler(M) and returns: math,  math,  math