To record hyperparameters in VESSL experiments, set vessl.hp and update with vessl.hp.update as follows.

Option 1: record hyperparameters with Python dictionary

import vessl

d = {"lr": 0.1, "optimizer": "sgd"}

Option 2: record hyperparameters with Python argparse module

import argparse
import vessl

parser = argparse.ArgumentParser()
parser.add_argument('-n', '--num_layers', type=int, default=3)
args = parser.parse_args(args=[])


Option 3: record hyperparameters with vessl.init()

vessl.init will have no effect in a VESSL-managed experiment.

You can pass hyperparameters as a parameter of init.

import vessl

d = {"lr": 0.1, "optimizer": "sgd"}

Or, you can call vessl.init() first, set vessl.hp, and call vessl.hp.update() without any parameters.

import vessl

vessl.init() = 0.1
vessl.hp.optimizer = "sgd"  # vessl.hp = {'lr': '0.1', 'optimizer': 'sgd'}