docstr: Returns True if a data conversion from dtype _from to _to is lossless, otherwise
  False.
docstr_tok: ["Returns","True","if","a","data","conversion","from","dtype","_from","to","_to","is","lossless",",","otherwise","False","."]
code: def __is_lossless(self, _from, _to):
      """
      Returns True if a data conversion from dtype _from to _to is lossless, otherwise
      False.
      """
      __int_order = [scipy.int8, scipy.int16, scipy.int32, scipy.int64]
  
      __uint_order = [
          scipy.uint8,
          scipy.int16,
          scipy.uint16,
          scipy.int32,
          scipy.uint32,
          scipy.int64,
          scipy.uint64,
      ]
  
      __float_order = [scipy.float32, scipy.float64, scipy.float128]
  
      __complex_order = [
          scipy.complex64,
          scipy.complex128,
          scipy.complex256,
      ]
  
      __bool_order = [
          scipy.bool_,
          scipy.int8,
          scipy.uint8,
          scipy.int16,
          scipy.uint16,
          scipy.int32,
          scipy.uint32,
          scipy.int64,
          scipy.uint64,
      ]
  
      __orders = [
          __int_order,
          __uint_order,
          __float_order,
          __complex_order,
          __bool_order,
      ]
  
      for order in __orders:
          if _from in order:
              if _to in order[order.index(_from) :]:
                  return True
              else:
                  return False
      return False
  
file_path: medpy/tests/io_/loadsave.py
imports: import unittest
  import tempfile
  import os
  import scipy
  from medpy.io import load, save
  from medpy.core.logger import Logger
label_desc: Use image node_id 3 for calling the TestIOFacilities obj's underlying member method code with example usage: obj.__is_lossless(_from, _to) and returns: False, True, False