Working with Data Assets in a Capsule

Attaching Data Assets to a Capsule

You can attach a data asset to one or more capsules to use in your computations. This means that the data won’t be copied back and forth to your Cloud Workstation, which reduces the capsule's size and speeds up the cloud workstation.

From the IDE

  1. Go to the data folder and click Manage Datasets.

  2. Click + Attach Data and pick the relevant data asset(s).

  3. Click Attach Data.

  4. The data is attached. It appears under the data folder. Click on it to see all the files.

From a Cloud Workstation (e.g., RStudio, Terminal, or Jupyter)

  1. Click Manage Datasets from the title bar.

  2. Click + Attach Data and pick the relevant data asset(s).

  3. Click Attach Data. The data is attached.

You can display more information about datasets by clicking on Show more in the Attach Data form.

When attaching an external dataset, the following points should be considered:

  1. To link to an external dataset, you need to add the secret to the capsule for accessing AWS S3. Check out Accessing a Secret in a capsule for more information.

  2. Since a secret is attached to the capsule, you will not be able to publish this capsule but only collaborate on this capsule by sharing it with others.

  3. Since the data is not saved on the Code Ocean server, you cannot see the content in the capsule IDE.

  4. Due to AWS S3 behavior, it takes time to reach files.

Removing a Data Asset from a Capsule

From the IDE

  1. Go to the data folder and click Manage Datasets.

  2. Click Remove.

From a Cloud Workstation (e.g., RStudio, Terminal, or Jupyter)

  1. Click Tools > Manage Data from the title bar.

  2. Click X next to the data asset.

Renaming the Mounting Point (Folder)

After you have attached a dataset to your capsule, you can change the name of the mounting point (that is, the folder name) in the Code Ocean IDE.

  1. Hover over the attached dataset under the /data folder.

  2. Click on the down arrow.

  3. Select Rename.

Last updated