Closed egpbos closed 2 months ago
Fixed the import issue from the previous CI build (tested locally). However, now we have a different, unrelated issue that we have to wait to get fixed (see #827 and #829).
I rebased on main to get the linter fix in here. The changes themselves look good, nice generalization of to_xarray! Linter's happy as well, so let's merge.
@egpbos many checks are not passing.
Yep, those are mentioned above. They are unrelated to this PR.
closing and reopening for rerunning tests
This commit makes dianna swallow more kinds of data items without users having to mangle them manually themselves. As long as your data is numpy ArrayLike it will go. The only blocker for this was the direct use of the .ndim attribute on data, which assumes it is already a numpy array rather than something that can trivially be converted to a numpy array. A PIL.Image is an example of such an ArrayLike type. We use this in explainable_embedding to feed items into the OpenAI CLIP model.
I sprinkled in some nice type hinting, of course, but not for the other parameters, because they would become monstrosities.