I want to compute the volume integral $\iiint_V f(x,y,z) \ dV$ over this volume $V$. The volume is a cylinder whose base has a stadium-like shape (it is a rectangle with semi-circles at the ends). Although I can evaluate $f(x,y,z)$ for every point $(x,y,z)$ in space and that the shape itself is relatively simple, I couldn't find a way to write down analitically the limits of integration for $x$, $y$ and $z$ (or for any other common coordinates such as spherical or cylindrical) because the origin lies outside the volume (and I can't just move the origin for a more suitable position because of other reasons).
Therefore, I really think the only way is to do it numerically. It's the first time I face this isssue, but I would like to do it in Python. I searched for Python modules and the standard one seems to be scipy.integrate (I guess Numpy also has similar functions), but the functions require the limits of integration, which I can't specify.
So, are there Python tools/packages that allow me to do the integral without explicitly passing the limits of integration? For example, if I could create a 3D mesh and discretize the shape into small volume elements, then I believe that would work, as long as I knew the position of each element belonging to the shape.