Difference between revisions of "CCU:Global dataset storage"

From Collective Computational Unit
Jump to navigation Jump to search
m (Overview)
(Writing your data to the global storage)
Line 7: Line 7:
 
== Writing your data to the global storage ==
 
== Writing your data to the global storage ==
  
 +
The global storage is populated from the subdirectory "datasets/cluster" in your home directory on the CCU master node Lolth (ccu-master.inf.uni-konstanz.de, IP 134.34.224.84). If you try to login there with ssh, the shell is extremely limited for security reasons. However, you can run an rsync command to the server as follows. Assume the current directory contains a subdirectory "my_dataset" which you want to copy to the global storage on the cluster, then run
  
 +
<syntaxhighlight lang="bash">
 +
> rsync -avz --info=progress2 ./my_dataset your.username@ccu-master.inf.uni-konstanz.de:datasets/cluster/
 +
</syntaxhighlight>
 +
 +
You now have a copy of your dataset on Lolth.
 +
 +
What happens now is that every hour, the datasets are synced to the directory "/raid/datasets/your.username" on the cluster. You can check if your data is already there by creating a test container with the following configuration:
 +
 +
<syntaxhighlight lang="yaml">
 +
</syntaxhighlight>
 +
 +
Once it has been copied, you can mount it into any container running on the cluster. Note that every user has read access to the whole directory tree, so you can use this method to share data between users as well.
  
 
== Accessing the global storage from within a container ==
 
== Accessing the global storage from within a container ==

Revision as of 12:15, 23 September 2020

Overview

The global dataset storage is intended for large, static datasets, in particular those which benefit multiple users (but feel free to also use it for your own data which only you need). Write access is very slow since it is tunneled over a slow filesystem for security and backup reasons (see below for technical details), so it will take a while until your datasets actually show up on the cluster. Read access, however, should be very fast, and might in some cases even surpass local storage.

The global storage can be easily mounted in any container on any node as a read-only volume, while you have to write to it using certain rsync commands on the master node. See below for detailed instructions. Every user has their own subdirectory within the global storage (readable by everyone, writeable only by that user). In addition, there is a user-independent directory subtree with common machine learning datasets. If you believe you have a dataset in your own subdirectory which is static and beneficial for many users, please contact me to move it to the common tree.

Writing your data to the global storage

The global storage is populated from the subdirectory "datasets/cluster" in your home directory on the CCU master node Lolth (ccu-master.inf.uni-konstanz.de, IP 134.34.224.84). If you try to login there with ssh, the shell is extremely limited for security reasons. However, you can run an rsync command to the server as follows. Assume the current directory contains a subdirectory "my_dataset" which you want to copy to the global storage on the cluster, then run

> rsync -avz --info=progress2 ./my_dataset your.username@ccu-master.inf.uni-konstanz.de:datasets/cluster/

You now have a copy of your dataset on Lolth.

What happens now is that every hour, the datasets are synced to the directory "/raid/datasets/your.username" on the cluster. You can check if your data is already there by creating a test container with the following configuration:

Once it has been copied, you can mount it into any container running on the cluster. Note that every user has read access to the whole directory tree, so you can use this method to share data between users as well.

Accessing the global storage from within a container

Please see this page for an introduction on how to use the datasets.


List of datasets in global storage

Everyone, please update this list if you have any useful datasets to share. Feel free to generate additional pages on the Wiki in case a dataset needs more description, or link to your project page in the respective column (see example below).


The KITTI Vision Dataset

  • Description:

Kitti contains a suite of vision tasks built using an autonomous driving platform. The full benchmark contains many tasks such as stereo, optical flow, visual odometry, etc. This dataset contains the object detection dataset, including the monocular images and bounding boxes. The dataset contains 7481 training images annotated with 3D bounding boxes. A full description of the annotations can be found in the readme of the object development kit readme on the Kitti homepage.

# KITTI Dataset
└── /mnt/dataset_kitti
       ├── training    <-- 7481 train data
       |   ├── image_2 <-- for visualization
       |   ├── calib
       |   ├── label_2
       |   ├── velodyne
       |   └── velodyne_reduced <-- empty directory
       └── testing     <-- 7580 test data
           ├── image_2 <-- for visualization
           ├── calib
           ├── velodyne
           └── velodyne_reduced <-- empty directory


To find the dataset, just tip

> kubectl get pvc

and you will get the information like following:

pvc name: dataset-kitti, capacity: 100Gi, access modes: RWO, storageclass:ceph-ssd

To access to the dataset, you can get a root shell inside the container as usual (insert the correct pod name you used below):

> kubectl exec -it user-name-pvc-access-pod /bin/bash

Then access into the dataset like following:

root@user-name-pvc-access-pod:/# cd mnt/dataset-kitti/
root@user-name-pvc-access-pod:/mnt/dataset-kitti#

If you want to bind your project to this global dataset, please change your job-script-pvc.yaml like following:

...
        # list of mount paths within the container which will be
        # bound to persistent volumes.
        volumeMounts:
        # /tmp/data is where mnist.py will download the training data, unless it is
        # already there. This is the path where we mount the persistent volume.
        # Thus, for the second run of this container, the data will
        # not be downloaded again.
        - mountPath: "/mnt/dataset_kitti"
        #  # name of the volume for this path (from the below list)
          name: dataset-kitti-user

      # login credentials to the docker registry.
      # for convenience, a readonly credential is provided as a secret in each namespace.
      imagePullSecrets:
      - name: registry-ro-login

      # containers will never restart
      restartPolicy: Never

      volumes:
        # User-defined name of the persistent volume within this configuration.
        # This can be different from the name of the PVC.
        - name: dataset-kitti-user
          persistentVolumeClaim:
            # name of the PVC this volume binds to
            claimName: dataset-kitti
...







TBC->nuScenes dataset