mayatk is a collection of backend utilities for Autodesk Maya.
To install:
Add the mayatk
folder to a directory on your python path, or
install via pip in a command line window using:
python -m pip install mayatk
import mayatk as mtk
mtk.is_group(<obj>)
# Returns: bool
mtk.get_bounding_box(<obj>, 'centroid|size')
# Returns: tuple containing bounding box center and size.
# ex. ((-0.02406523456116849, -0.8100277092487823, 0.0), (3.3830200057098523, 4.0155477063595555, 3.40770764056194))