Connecting to external data
Overview
If you are storing images in the external data source such as amazon aws or Google Drive, you can connect to these images from AnnoStation.
These images will remain in the external data source and will not be uploaded to AnnoStation.
To connect to the external data source, you need to follow these steps:
Prepare a CSV file
Import the CSV file to AnnoStation
Configure the CORS settings
Prepare CSV file
Include the following fields in your CSV file.
Field
Description
filename
A user generated image name. This string is used as a name of the image in AnnoStation.
imageURL
HTTPS path to the external image URL
Example:
Import CSV file
To import the CSV file to AnnoStation:
Select New and choose
Import file
.Click the
Use External Data
tab.Select Choose File and then select the CSV file you prepared.
Click Import.
Check the URL of the image file
You can check the URL manually for images that are stored in the external data source, and then change the value if needed.
Go to an image you want to check the URL path, select the
...
button on the right and then chooseFile settings
.This opens the External dataset editing dialog. You can change the file name and URL, and click on Save.
Setup Cross-origin resource sharing (CORS) option
Cross-origin resource sharing (CORS) is a mechanism that allows resources, in this case images, to be requested from AnnoStation which belongs to another domain outside the domain from which the first resource was served such as amazon aws or Google Drive.
In order for AnnoStation to successfully display an image, you need to configure the external data source to allow cross-origin requests.
If cross-origin requests are not allowed, AnnoStation will not be able to display images. In that case, you can force all the images to be rendered from the AnnoStation server. To turn it on:
Go to the
Setting
page of the Project.Open
Advanced settings
, and then selectForce all the images render from server to prevent CORS issue
.Click on Update Project.
If the image cannot be displayed due to the CORS issue, AnnoStation will display the error message. If you see the error, try enabling the CORS option.
Last updated
Was this helpful?