class_docstr: This class represents masks in the form of bitmaps.
  
  Args:
      masks (ndarray): ndarray of masks in shape (N, H, W), where N is
          the number of objects.
      height (int): height of masks
      width (int): width of masks
class_docstr_tok: ["This","class","represents","masks","in","the","form","of","bitmaps",".","Args",":","masks","(","ndarray",")",":","ndarray","of","masks","in","shape","(","N",",","H",",","W",")",",","where","N","is","the","number","of","objects",".","height","(","int",")",":","height","of","masks","width","(","int",")",":","width","of","masks"]
docstr: Shear the BitmapMasks.
  
  Args:
      out_shape (tuple[int]): Shape for output mask, format (h, w).
      magnitude (int | float): The magnitude used for shear.
      direction (str): The shear direction, either "horizontal"
          or "vertical".
      border_value (int | tuple[int]): Value used in case of a
          constant border.
      interpolation (str): Same as in :func:`mmcv.imshear`.
  
  Returns:
      BitmapMasks: The sheared masks.
docstr_tok: ["Shear","the","BitmapMasks",".","Args",":","out_shape","(","tuple","[","int","]",")",":","Shape","for","output","mask",",","format","(","h",",","w",")",".","magnitude","(","int","|","float",")",":","The","magnitude","used","for","shear",".","direction","(","str",")",":","The","shear","direction",",","either","``","horizontal","''","or","``","vertical","''",".","border_value","(","int","|","tuple","[","int","]",")",":","Value","used","in","case","of","a","constant","border",".","interpolation","(","str",")",":","Same","as","in",":","func",":","`","mmcv.imshear","`",".","Returns",":","BitmapMasks",":","The","sheared","masks","."]
code: def shear(
      self,
      out_shape,
      magnitude,
      direction="horizontal",
      border_value=0,
      interpolation="bilinear",
  ):
      """Shear the BitmapMasks.
  
      Args:
          out_shape (tuple[int]): Shape for output mask, format (h, w).
          magnitude (int | float): The magnitude used for shear.
          direction (str): The shear direction, either "horizontal"
              or "vertical".
          border_value (int | tuple[int]): Value used in case of a
              constant border.
          interpolation (str): Same as in :func:`mmcv.imshear`.
  
      Returns:
          BitmapMasks: The sheared masks.
      """
      if len(self.masks) == 0:
          sheared_masks = np.empty((0, *out_shape), dtype=np.uint8)
      else:
          sheared_masks = mmcv.imshear(
              self.masks.transpose((1, 2, 0)),
              magnitude,
              direction,
              border_value=border_value,
              interpolation=interpolation,
          )
          if sheared_masks.ndim == 2:
              sheared_masks = sheared_masks[:, :, None]
          sheared_masks = sheared_masks.transpose((2, 0, 1)).astype(
              self.masks.dtype
          )
      return BitmapMasks(sheared_masks, *out_shape)
  
imports: from abc import ABCMeta, abstractmethod
  import cv2
  import mmcv
  import numpy
  import pycocotools.mask
  import torch
  from mmcv.ops.roi_align import roi_align
label_desc: Use image node_id 14 for calling the BitmapMasks obj's underlying member method code with example usage: obj.shear(out_shape, magnitude, direction, border_value, interpolation) and returns: BitmapMasks