Fix serialising of image annotations

- Remove circular references