class_docstr: Class to wrap general DICOM files
  
  Methods:
  
  * get_data()
  * get_pixel_array()
  * is_same_series(other)
  * __getitem__ : return attributes from `dcm_data`
  * get(key[, default]) - as usual given __getitem__ above
  
  Attributes and things that look like attributes:
  
  * affine : (4, 4) array
  * dcm_data : object
  * image_shape : tuple
  * image_orient_patient : (3,2) array
  * slice_normal : (3,) array
  * rotation_matrix : (3,3) array
  * voxel_sizes : tuple length 3
  * image_position : sequence length 3
  * slice_indicator : float
  * series_signature : tuple
code: def _apply_scale_offset(self, data, scale, offset):
      # a little optimization.  If we are applying either the scale or
      # the offset, we need to allow upcasting to float.
      if scale != 1:
          if offset == 0:
              return data * scale
          return data * scale + offset
      if offset != 0:
          return data + offset
      return data
  
imports: import operator
  import warnings
  import numpy
  from nibabel.optpkg import optional_package
  from ..onetime import auto_attr
  from ..openers import ImageOpener
  from .None import csareader
  from .dwiparams import B2q, nearest_pos_semi_def, q2bg
label_desc: Use image node_id 18 for calling the Wrapper obj's underlying member method code with example usage: obj._apply_scale_offset(data, scale, offset) and returns: data, unknown, unknown, unknown