Skip to content

Getting started with shrike examples

You will find 3 example experiments using shrike in the examples folder:

  1. Example ./examples/pipelines/experiments/demo_component_with_parameter.py is for running a basic experiment demonstrating how to consume a parameter value and operate on it.
  2. Example ./examples/pipelines/experiments/demo_count_rows_and_log.py is for running a basic experiment demonstrating how to use shrike for logging, and how to consume a dataset.
  3. Example ./examples/pipelines/experiments/demo_image_classification.py is for running an image classification experiment, containing data ingestion, preprocess data, train model, evaluate model, deploy model steps. This example is built upon an AML pipeline demo without shirke. Once the pipeline run finishes successfully, you can use the trained model for inference on any images using script ./examples/inference/demo_test_image_classification_endpoint.py.

Setup

  • Provision a public AML workspace (you can find instructions here). Then, fill in the ./examples/pipelines/config/aml/public_workspace.yaml file with the details of your workspace.
  • Note that you do NOT want a Heron a.k.a. eyes-off a.k.a. compliant workspace. This introductory problem set is fairly general and does not touch on compliance-specific notions, so using a Heron workspace would make things more complicated.
  • Set up and activate a new Conda environment:
    conda create --name shrike-examples-env python=3.7 -y 
    conda activate shrike-examples-env
    
  • Install the shrike dependencies
    pip install -r requirements.txt
    
  • Clone the current repository and set examples as your working directory.