When running the image_series_annotator, the first image in the series incorrectly reports that embeddings have not been calculated, even when they have been precomputed for all images. Rerunning the embedding computation resolves it temporarily, but if an embedding_path is set, it throws an error until the embedding path is removed.
The root cause seem to be in the _load_image helper function, which accepts an image_id parameter but ignores it — instead reading next_image_id from the outer scope.
A related issue exists in _save_segmentation, which similarly ignores its current_idx parameter in favour of the outer next_image_id.
master...maartenpaul:micro-sam:series_annotator_issues
I'm happy to open a PR with a fix.