NUVOLOS
Sign In
  • Getting Started
    • Introduction to Nuvolos
    • Documentation structure
    • Nuvolos basic concepts
      • Organisational hierarchy
      • Applications
      • Distribution
      • Data integration
      • Snapshots
      • Background tasks
    • Navigate in Nuvolos
    • Quickstart tutorials
      • Research
      • Education (instructor)
      • Education (student)
  • Features
    • Applications
      • Application resources
      • Sessions
        • Session Logs
      • Install a software package
      • Create a persistent .bashrc
      • Automatic code execution
      • Long-running applications
      • Troubleshooting applications
      • New applications or licenses
      • Configuring applications
      • Exporting applications
      • Add-ons
        • MariaDB add-on
        • PostgreSQL add-on
        • OpenSearch add-on
        • MongoDB add-on
        • Redis add-on
        • PostGIS add-on
        • Rclone mount add-on
        • Neo4j add-on
    • File system and storage
      • File navigator
      • Large File Storage
      • Preview files
      • Mount Dropbox
      • Access S3 buckets with RClone
      • Access remote files with SSHFS
      • Access files on SharePoint Online
    • Object distribution
      • Distribution strategies
      • The distributed instance
    • Snapshots
      • Create a snapshot
      • Restore a snapshot
      • Delete a snapshot
    • Database integration
      • Create datasets
      • View tables
      • Build queries
      • Upload data
      • Access data from applications
        • Set up ODBC drivers
        • Obtain tokens for data access
        • Find database and schema path
      • DBeaver integration
    • Environment variables and secrets
    • Searching
      • Page
      • Find an application
      • Find an organisation
      • Find a space
      • Find an instance
      • Find a state
    • Video library
    • Nuvolos CLI and Python API
      • Installing the CLI
      • Using the CLI
  • User Guides
    • Research guides
      • Inviting a reviewer
      • GPU computation
    • Education guides
      • Setting assignments
        • Programmatical assignment handling
      • Documenting your course
      • Setting up group projects
        • Collaborative application editing
      • Configuring student applications
      • Archiving your course
      • Student guides
        • Joining a course
        • Working on assignments
        • Leaving a course
    • Application-specific guides
      • JupyterLab
      • RStudio
      • VSCode
      • Stata
      • MATLAB
      • Terminal
      • Terminal [tmux]
      • Apache Airflow
      • Apache Superset
      • D-Wave Inspector
      • MLFlow
      • Databricks Connect
      • Dynare.jl
      • CloudBeaver
      • InveLab
      • Overleaf
      • Metabase
      • DNDCv.CAN
      • OpenMetaData
      • Uploading data to the Large File Storage
    • Data guides
      • Setting up a dataset on Nuvolos
      • Importing data on Nuvolos
      • A complete database research workflow (Matlab & RStudio)
      • Accessing data as data.frames in R
      • Working with CRSP and Compustat
      • Working with the S&P 500®
  • Pricing and Billing
    • Pricing structure
    • Resource pools and budgets
    • Nuvolos Compute Units (NCUs)
  • Administration
    • Roles
      • Requesting roles
    • Organisation management
    • Space management
      • Invite to a space
      • Revoke a space user
      • HPC spaces
      • Resting spaces
    • Instance management
      • Invite to an instance
    • Enabling extra services
    • Monitoring resource usage
  • Reference
    • Application reference
      • InveLab
        • Dataset selection
        • Modules
          • Time-series visualisation
          • Moment estimation
          • Mean-variance frontiers
          • Frontiers
          • Dynamic strategy
          • Portfolio analysis
          • Performance analysis
          • Benchmarking
          • Carry trade strategies
          • Risk measures
          • Conditional volatility
          • Replication
          • Factor factory
          • Factor tilting
          • Valuation
    • Glossary
  • FAQs
    • FAQs
    • Troubleshooting
      • Login troubleshooting
        • I forgot my email address
        • I forgot my identity provider
        • I can't log in to Nuvolos
        • I forgot my password
        • I haven't received the password reset email
        • I haven't received the invitation email
      • Application troubleshooting
        • I can't see an application
        • I can't start an application
        • I can't create an application
        • I can't delete an application
        • I can't stop a running application
        • JupyterLab 3 troubleshooting
        • Spyder 3.7 troubleshooting
      • Administration troubleshooting
        • I can't see a space
        • I can't create a space
        • I can't delete a space
        • I can't invite admins to my space
        • I can't see an instance
        • I can't create an instance
        • I can't delete an instance
        • I can't invite users to an instance
        • I can't see distributed content in my instance
        • I can't see a snapshot
        • I can't create a snapshot
        • I can't delete a snapshot
        • I can't revoke a user role
        • I can't upload a file
        • I can't delete a file
        • I can't invite students to my course
      • Content troubleshooting
        • I can't find my files in my Linux home
        • I can't find my files among the Workspace files
        • I restored a snapshot by mistake
Powered by GitBook
On this page
  • Prerequisites
  • Installation
  • Basic usage
  • A tutorial workflow integrated with Otter
  • Obtain the otter tutorial
  • Modify demo.ipynb
  • Run otter assign
  • Create an Assignment on Nuvolos
  • Collect hand-ins
  • Grade hand-ins
  • Handing back

Was this helpful?

  1. User Guides
  2. Education guides
  3. Setting assignments

Programmatical assignment handling

This is a new and experimentary feature of Nuvolos, please provide us with feedback to make it better!

It is possible to collect assignments from a project using a command line tool currently available in applications from our support on request.

The name of the tool is nvcollect and it is intended to help you in programmatically collecting and handing back grading artfiacts.

Prerequisites

For the following example, please work in the Master (instructor's) instance.

Add a JupyterLab + TexLive application to the Master instance. This application will be used to grade the students' submissions with otter-grader.

Installation

To install nvcollect, run the following command from the terminal in your JupyterLab application:

pip install --upgrade git+https://github.com/alphacruncher/nv-collect

Basic usage

The tool makes it possible to:

  1. Collect assignments from all students to a folder in your instance.

  2. Grade assignments using the otter-grader package if your project supports this.

  3. Hand back assignments in a safe manner to all students with a single command.

A tutorial workflow integrated with Otter

In the guide we assume the following:

  • You have access to a JupyterLab image that supports TexLive, pandoc, otter-grader and you have installed nv-collect.

Obtain the otter tutorial

To get the files referred by the otter tutorial, open a JupyterLab terminal and hit

wget https://otter-grader.readthedocs.io/en/latest/_static/tutorial.zip
unzip tutorial.zip

Modify demo.ipynb

The demo.ipynb file that is provided by otter-grader is not completely compatible with Nuvolos. The reason is that the demo assumes that the environment has a window system - this is not true in Nuvolos. In order to fix this issue, in the second cell instead of

%matplotlib inline

make sure to have

import matplotlib
matplotlib.use('Agg')

Run otter assign

Following the steps of the tutorial execute the following command in the directory where you unzipped the tutorial zipfile:

otter assign demo.ipynb dist --v1

This command creates a dist directory in which the artifacts required for the autograding and assignment distribution are added.

The dist/student/demo.ipynb file is the stripped-down, simplified, user-friendly file that your students will have to fill out.

Create an Assignment on Nuvolos

In our example, we copy the file from /files/otter-test/dist/student/demo.ipynb to /files/assignment_1/demo.ipynb, then we stage the entire folder and distribute it as an assignment to our students. We give the assignment the name "assignment_1" in Nuvolos when creating the assignment (this doesn't have to be the same as the folder name containing the assignment, but it is generally good practice to have the same).

Collect hand-ins

Once the assignment deadline has passed, the assignments are ready to be collected. We use the following command available in the JupyterLab terminal to collect:

nvcollect collect --assignment_name "assignment_1" --assignment_folder assignment_1 --target_folder /files/test_collect

This tells the collect tool to gather from all students whatever is contained in the assignment_1 folder in the Nuvolos assignment called "assignment_1" and the collected files should be placed under /files/test_collect.

The directory structure will be as such:

/files/test_collect
+-- nvcollect_manifest.json
+-- single_user_inst_<code1>
|   +-- ...
+-- single_user_inst_<code2>
|   +-- ...

Grade hand-ins

In order to grade hand-ins we need to use the autograder.zip file generated in Step 3. To grade all collected assignments:

nvcollect otter-grade --source_folder /files/test_collect --autograder_location /files/otter-test/dist/autograder/autograder.zip --relative_path demo.ipynb

Observe the following:

  • source_folder is the same folder as provided as target_folder to the collection command.

  • You have to provide the absolute path of the autograder.zip file that belongs to the particular notebook file you want to grade.

  • The relative_path parameter tells the tool where to look for in each student submission directory for the notebook file that needs to be graded.

As an outcome of the grading, you get the following new items in the source_folder:

  • A grade.csv file which contains the score of each student.

  • A grade.csv file in each student folder which contains the score of the student.

Handing back

You might want to add additional artifacts to each students folders (either manually or programmatically). Once you are done with this, you can push back the results of the grading with the command

nvcollect handback --source_folder /files/test_collect
  • Notice that the source_folder here is the same folder to which we collected and then in which the grading process ran.

PreviousSetting assignmentsNextDocumenting your course

Last updated 4 months ago

Was this helpful?

This guide relies on using the otter-grader package and demonstrates how the otter tutorial found can be adapted to the Nuvolos workflow. This package requires TexLive to function properly which is only available currently on request from our support.

Please refer to our on creating assignments. Make sure to copy dist/student/demo.ipynb to some separate folder which you can safely stage and assign.

here
guide