def dict_to_numpy_array(d, mapping=None):
 try:
  return dict_to_numpy_array2(d, mapping)
 except (AttributeError, TypeError):
  return dict_to_numpy_array1(d, mapping)

def dict_to_numpy_array ( d , mapping = None ) : try : return dict_to_numpy_array2 ( d , mapping ) except ( AttributeError , TypeError ) : return dict_to_numpy_array1 ( d , mapping )
convert a dictionary of dictionaries to a numpy array with optional mapping .