Scott Todd | 619c420 | 2019-11-26 17:50:31 -0800 | [diff] [blame] | 1 | # Google Colaboratory (Colab) Notebooks |
| 2 | |
Scott Todd | b3cd60a | 2023-10-12 09:40:30 -0700 | [diff] [blame] | 3 | These [Colab](https://colab.google/) notebooks contain interactive sample |
| 4 | applications using IREE's Python bindings and ML framework integrations. |
| 5 | |
Scott Todd | 619c420 | 2019-11-26 17:50:31 -0800 | [diff] [blame] | 6 | ## Notebooks |
| 7 | |
Scott Todd | b3cd60a | 2023-10-12 09:40:30 -0700 | [diff] [blame] | 8 | Framework | Notebook file | Description | Link |
| 9 | -------- | ------------- | ----------- | ---- |
Scott Todd | 3f51a55 | 2024-04-19 11:00:27 -0700 | [diff] [blame] | 10 | Generic | [low_level_invoke_function](low_level_invoke_function.ipynb) | Shows low level IREE python binding concepts | [](https://colab.research.google.com/github/iree-org/iree/blob/main/samples/colab/low_level_invoke_function.ipynb) |
Scott Todd | 8aae294 | 2024-06-07 14:14:22 -0700 | [diff] [blame] | 11 | PyTorch | [pytorch_aot_advanced](pytorch_aot_advanced.ipynb) | Uses [Turbine](https://github.com/iree-org/iree-turbine) to export a PyTorch program | [](https://colab.research.google.com/github/iree-org/iree/blob/main/samples/colab/pytorch_aot_advanced.ipynb) |
| 12 | PyTorch | [pytorch_aot_simple](pytorch_aot_simple.ipynb) | Uses [Turbine](https://github.com/iree-org/iree-turbine) to export a simple PyTorch program | [](https://colab.research.google.com/github/iree-org/iree/blob/main/samples/colab/pytorch_aot_simple.ipynb) |
| 13 | PyTorch | [pytorch_jit](pytorch_jit.ipynb) | Uses [Turbine](https://github.com/iree-org/iree-turbine) for eager execution in a PyTorch session | [](https://colab.research.google.com/github/iree-org/iree/blob/main/samples/colab/pytorch_jit.ipynb) |
Scott Todd | d12291f | 2024-04-22 14:40:50 -0700 | [diff] [blame] | 14 | PyTorch | [pytorch_huggingface_whisper](pytorch_huggingface_whisper.ipynb) | Imports the [Whisper](https://huggingface.co/openai/whisper-small) model from [Hugging Face](https://huggingface.co/) | [](https://colab.research.google.com/github/iree-org/iree/blob/main/samples/colab/pytorch_huggingface_whisper.ipynb) |
Scott Todd | 3f51a55 | 2024-04-19 11:00:27 -0700 | [diff] [blame] | 15 | TensorFlow | [tensorflow_edge_detection](tensorflow_edge_detection.ipynb) |Performs image edge detection | [](https://colab.research.google.com/github/iree-org/iree/blob/main/samples/colab/tensorflow_edge_detection.ipynb) |
| 16 | TensorFlow | [tensorflow_hub_import](tensorflow_hub_import.ipynb) | Imports a [MobileNet V2](https://tfhub.dev/google/tf2-preview/mobilenet_v2/classification) model from [TensorFlow Hub](https://tfhub.dev/) | [](https://colab.research.google.com/github/iree-org/iree/blob/main/samples/colab/tensorflow_hub_import.ipynb) |
| 17 | TensorFlow | [tensorflow_mnist_training](tensorflow_mnist_training.ipynb) | Compiles, trains, and executes a neural network | [](https://colab.research.google.com/github/iree-org/iree/blob/main/samples/colab/tensorflow_mnist_training.ipynb) |
Scott Todd | d12291f | 2024-04-22 14:40:50 -0700 | [diff] [blame] | 18 | TensorFlow | [tensorflow_resnet](tensorflow_resnet.ipynb) | Runs a pretrained [ResNet50](https://www.tensorflow.org/api_docs/python/tf/keras/applications/ResNet50) model | [](https://colab.research.google.com/github/iree-org/iree/blob/main/samples/colab/tensorflow_resnet.ipynb) |
| 19 | TFLite | [tflite_text_classification](tflite_text_classification.ipynb) | Runs a pretrained [text classification](https://www.tensorflow.org/lite/examples/text_classification/overview) model | [](https://colab.research.google.com/github/iree-org/iree/blob/main/samples/colab/tflite_text_classification.ipynb) |
not-jenni | a07a112 | 2021-06-02 01:46:08 -0700 | [diff] [blame] | 20 | |
Scott Todd | 619c420 | 2019-11-26 17:50:31 -0800 | [diff] [blame] | 21 | ## Working with GitHub |
| 22 | |
| 23 | Refer to |
Jacques Pienaar | a4b8ccb | 2023-11-08 09:55:22 -0800 | [diff] [blame] | 24 | [Colab's GitHub demo](https://colab.research.google.com/github/googlecolab/colabtools/blob/main/notebooks/colab-github-demo.ipynb) |
Scott Todd | 619c420 | 2019-11-26 17:50:31 -0800 | [diff] [blame] | 25 | for general information about using Colab with GitHub. |
| 26 | |
| 27 | To make changes to a notebook in this repository, one possible workflow is: |
| 28 | |
| 29 | * Open or create the notebook in Colab |
Scott Todd | 982db73 | 2021-01-08 10:16:25 -0800 | [diff] [blame] | 30 | * Connect to a hosted or local runtime |
Scott Todd | 619c420 | 2019-11-26 17:50:31 -0800 | [diff] [blame] | 31 | * Make your changes, run the notebook, etc. |
| 32 | * Download the modified notebook using `File > Download .ipynb` |
| 33 | * Move the downloaded notebook file into a clone of this repository and submit |
| 34 | a pull request |
Scott Todd | b3cd60a | 2023-10-12 09:40:30 -0700 | [diff] [blame] | 35 | |
| 36 | ## Testing |
| 37 | |
| 38 | This notebooks are tested continuously by the samples.yml CI job. |