Add bounding box calculation and other function in calculations.py

* Vertex arrays may have ndim > 2 
* Some vertex arrays have `shape[-1] == 4`