Remove unused map iter_by_pix and iter_by_coord methods #2206
This PR removes the map iter_by_pix and iter_by_coord methods.
They are unused in Gammapy, no use case has come up for this so far. The use case given in the docs could just as well and much more efficiently be written by using the whole map directly, or by using
Iterating over pixels in Python will never be efficient, should always be avoided. Almost all computations can be expressed using Numpy, and should that not be possible, one could use Numba or Cython, or if really needed, do this Python pixel loop where it's needed.
IMO we shouldn't leave such code in Gammapy, but start to either remove or improve quality as we work towards Gammapy v1.0. Note that this code is non-trivial and likely not very well written. E.g. the docstring of
The text was updated successfully, but these errors were encountered: