Quick-start: PrimeHub Community/Enterprise
Brief
In this quick-start we will learn how to train/generate a simple model on Notebook, in the follow-up, we will learn how to submit a parameter-tuning job for the model tuning from same Notebook.
- Notebook is a fundamental feature of Community/Enterprise editions.
- Jobs is a feature of Enterprise edition.
Training a model on Notebook
What we need?
The image
infuseai/docker-stacks:tensorflow-notebook-v2-4-1-5b5a244cAn instance type >= minimal requirement (CPU=1, GPU=0, Mem=2G)
The prepared notebook file of the example
Download my_model.ipynb
Choose a group with enabled Shared Volume (a.k.a Group Volume)
Please have the image, the instance type on PrimeHub or request administrators for the assistance before we start.
Steps
- Enter Notebook from User Portal, select the image, the instance type and start a notebook.

From File Browser of Notebook, navigate into the directory of
<group_name>which is a Group Volume; here data-team is our working group.While inside the group volume, copy/drag the downloaded
my_model.ipynbthere in File Browser and open it.Run All Cells, it will save the model file
my_model.h5at the local.
We so far have trained and generated a model file on Notebook. This is achievable to Community/Enterprise users.
The next follow-up, parameter-tuning job, is for Enterprise users. Remain the Notebook environment open, let's go to the next.
Parameter-tuning Job
What we need?
The same image as above
The same instance type as above
API Token
The prepared notebook file of the example
Download tune_params.ipynb
Steps
While inside the group volume, copy/drag the downloaded
tune_params.ipynband open it.Click on Cell 4, from Property Inspector, we can see the notebook has set
epochas aparameterSee Papermill site ⇗ for the detail of Parameterize.

Back to PrimeHub tab, hover over Profile icon, generate a API Token and copy it.

Back to Notebook tab, click
PrimeHubdropdown on the toolbar of the opened notebook, select API Token and paste the generated token here.

Click
PrimeHubdropdown again and selectSubmit Notebook as Jobthis time.Select the instance type and the image; fill in
Job Nametune_params_epoch_tf and
Fill in
Notebook Parameterswith the code below due toepochis parameterized.epoch = 2Back to PrimeHub tab, enter Jobs and check the job
tune_params_epoch_tfwe submitted.
Once the job succeeded, back to Notebook, we can find a notebook
tune_params-<datetime>of output by the job and the overwrittenmy_model.h5after tuning.
We now have walked through a typical flow of training and saving a simple model file, then submitting a job of tuning the generated on Notebook. In a real project, we may want to use various combinations of jobs and notebooks to pipeline repeatable workflows.
What's Next?
As Enterprise users, we desperately want to verify the performance of our model, therefore, we can deploy models as services and query the services with testing data.