GithubHelp home page GithubHelp logo

isabella232 / azureml-fastai Goto Github PK

View Code? Open in Web Editor NEW

This project forked from azure/azureml-fastai

0.0 0.0 0.0 1.22 MB

Example code showing how to run FastAI examples on Azure ML

License: MIT License

Shell 100.00%

azureml-fastai's Introduction

Use FastAI with Azure Machine Learning!

This repository has examples showing you how to use FastAI on Azure ML.

Create an ML workspace

The Azure Machine Learning workspace is the top-level resource for the service. It provides you with a centralized place to work with all the artifacts you create.

You can create an ML workspace by clicking here - specify a unique resource group name for your Azure subscription!:

Deploy To Azure

More details about deployment in the button used above, Check out ARM JSON definition and Azure Machine Learning VM sizes

Quick FastAI Environment setup

  1. Go to the Azure ML studio (https://ml.azure.com) and find your ML workspace.

  2. On the left side, select Notebooks. Select any notebook located in the User files section on the left-hand side. If you don't have any notebooks there, first create a notebook

Notebook

  1. Select the Open terminal icon. Open Terminal

  2. If you don't see the icon, select the ... to the right of the compute target and then select Open terminal . Open Terminal Mini

PRO-TIP: Copy and Paste in Terminal

  • Windows: Ctrl-c to copy is supported but use Shift-insert to paste.
  • FireFox/IE may not support clipboard permissions properly.
  • Mac OS: Cmd-c to copy and Cmd-v to paste.
  1. Copy the following command to clipboard:
wget https://raw.githubusercontent.com/Azure/AzureML-fastai/main/fastaionAMLCI.sh
bash fastaionAMLCI.sh

If you don't already have fastai, then you have to wait for the libraries and dependencies to install. Wait up to 10 mins for this to complete and continue to the next step.

All of the notebook samples should now be cloned into the fastai folder and ready to run!

  1. Refresh File Explorer to see all new files.

Refresh File Explorer

  1. If you didn't run into any errors, proceed to Running FastAI Notebook section

Manual FastAI Environment Setup

  1. Use the terminal window to create a new environment. For example, the code below creates fastaienv and activate the environment:
conda create -y --name fastaienv
conda activate fastaienv
  1. Install fastai, nbdev, pip and ipykernel package to the new environment and create a kernel for that conda env:
conda install -y pip
conda install -y ipykernel
conda install -y -c fastai -c pytorch fastai
conda install -y -c fastai fastbook
conda install -y -c fastai nbdev

If you don't already have fastai, then you have to wait for the libraries and dependencies to install. Wait up to 10 mins for this to complete and continue to the next step.

  1. Create a kernel for that conda env:
python -m ipykernel install --user --name fastaienv --display-name "Python (fastaienv)"
  1. Clone the Fast AI Repo with below snippet:
git clone https://github.com/fastai/fastai.git

All of the notebook samples should now be cloned into the fastai folder and ready to run!

  1. Refresh File Explorer to see all new files.

Refresh File Explorer

Running FastAI Notebooks

  1. Open a notebook in fastai/nbs you just cloned:

Open Notebooks

  1. Always make sure you select the Python (fastaienv) Kernel:

Fast AI Kernel

  1. Run all cells in Notebook:

Run All

Shutting down your compute

When you're down make sure you stop your compute! If you don't you'll keep getting charged until you click the stop compute button. Shutdown Compute

Returning back to work

When you want to go back to your notebook exercises, just find the notebook in the AzureML Studio and hit Play on any cell.

It will take a few mins to reboot your compute and run you cell. Make sure you have selected the Python (fastaienv) kernel when you notebook is running.

Contributing

This project welcomes contributions and suggestions. Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution. For details, visit https://cla.opensource.microsoft.com.

When you submit a pull request, a CLA bot will automatically determine whether you need to provide a CLA and decorate the PR appropriately (e.g., status check, comment). Simply follow the instructions provided by the bot. You will only need to do this once across all repos using our CLA.

This project has adopted the Microsoft Open Source Code of Conduct. For more information see the Code of Conduct FAQ or contact [email protected] with any additional questions or comments.

azureml-fastai's People

Contributors

jpe316 avatar abeomor avatar saachigopal avatar microsoftopensource avatar microsoft-github-operations[bot] avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.