Skip to content

Commit

Permalink
Merge branch 'main' into reuvenperetz-patch-2
Browse files Browse the repository at this point in the history
  • Loading branch information
ofirgo committed Feb 13, 2025
2 parents e070c95 + 345113d commit 2e565f2
Show file tree
Hide file tree
Showing 11 changed files with 12 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ in some operator for its weights/activations, fusing patterns, etc.)
## Supported Target Platform Models

Currently, MCT contains three target-platform models
(new models can be created and used by users as demonstrated [here](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html#targetplatformmodel-code-example)):
(new models can be created and used by users as demonstrated [here](https://github.com/sony/model_optimization/blob/main/model_compression_toolkit/target_platform_capabilities/tpc_models/imx500_tpc/v1/tpc.py)):
- [IMX500](https://developer.sony.com/develop/imx500/)
- [TFLite](https://www.tensorflow.org/lite/performance/quantization_spec)
- [QNNPACK](https://github.com/pytorch/QNNPACK)
Expand Down Expand Up @@ -50,4 +50,4 @@ quantized_model, quantization_info = mct.ptq.keras_post_training_quantization(Mo

Similarly, you can retrieve IMX500, TFLite and QNNPACK target-platform models for Keras and PyTorch frameworks.

For more information and examples, we highly recommend you to visit our [project website](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html#ug-target-platform).
For more information and examples, we highly recommend you to visit our [project website](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform_capabilities.html#ug-target-platform-capabilities).
Original file line number Diff line number Diff line change
Expand Up @@ -276,7 +276,7 @@
"cell_type": "markdown",
"source": [
"## Target Platform Capabilities\n",
"MCT optimizes the model for dedicated hardware. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html)). Here, we use the default Tensorflow TPC:"
"MCT optimizes the model for dedicated hardware. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform_capabilities.html)). Here, we use the default Tensorflow TPC:"
],
"metadata": {
"collapsed": false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@
"cell_type": "markdown",
"source": [
"## Target Platform Capabilities\n",
"MCT optimizes the model for dedicated hardware. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html)). Here, we use the default Tensorflow TPC:"
"MCT optimizes the model for dedicated hardware. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform_capabilities.html)). Here, we use the default Tensorflow TPC:"
],
"metadata": {
"collapsed": false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,7 @@
"source": [
"## Target Platform Capabilities (TPC)\n",
"In addition, MCT optimizes models for dedicated hardware platforms using Target Platform Capabilities (TPC). \n",
"**Note:** To apply mixed-precision quantization to specific layers, the TPC must define different bit-width options for those layers. For more details, please refer to our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html). In this example, we use the default Tensorflow TPC, which supports 2, 4, and 8-bit options for convolution and linear layers"
"**Note:** To apply mixed-precision quantization to specific layers, the TPC must define different bit-width options for those layers. For more details, please refer to our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform_capabilities.html). In this example, we use the default Tensorflow TPC, which supports 2, 4, and 8-bit options for convolution and linear layers"
],
"metadata": {
"collapsed": false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@
"cell_type": "markdown",
"source": [
"## Target Platform Capabilities\n",
"MCT optimizes the model for dedicated hardware. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html)). Here, we use the default Tensorflow TPC:"
"MCT optimizes the model for dedicated hardware. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform_capabilities.html)). Here, we use the default Tensorflow TPC:"
],
"metadata": {
"collapsed": false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@
"## MCT Structured Pruning\n",
"\n",
"### Target Platform Capabilities (TPC)\n",
"MCT optimizes models for dedicated hardware using Target Platform Capabilities (TPC). For more details, please refer to our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html)). First, we'll configure the TPC to define each layer's SIMD (Single Instruction, Multiple Data) size.\n",
"MCT optimizes models for dedicated hardware using Target Platform Capabilities (TPC). For more details, please refer to our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform_capabilities.html)). First, we'll configure the TPC to define each layer's SIMD (Single Instruction, Multiple Data) size.\n",
"\n",
"In MCT, SIMD plays a key role in channel grouping, influencing the pruning process by considering channel importance within each SIMD group.\n",
"\n",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@
"source": [
"## Preparing the Model for Hardware-Friendly Quantization Aware Training with MCT\n",
"## Target Platform Capabilities\n",
"MCT optimizes the model for dedicated hardware. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html)). In this tutorial, we use a TPC configuration that applies 2-bit quantization for weights and 3-bit quantization for activations.\n",
"MCT optimizes the model for dedicated hardware. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform_capabilities.html)). In this tutorial, we use a TPC configuration that applies 2-bit quantization for weights and 3-bit quantization for activations.\n",
"\n",
"If desired, you can skip this step and directly use the pre-configured [`get_target_platform_capabilities`](https://sony.github.io/model_optimization/api/api_docs/methods/get_target_platform_capabilities.html) function to obtain an initialized TPC."
],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@
},
"source": [
"## Target Platform Capabilities\n",
"MCT optimizes the model for dedicated hardware. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html)). Here, we use the default Tensorflow TPC:"
"MCT optimizes the model for dedicated hardware. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform_capabilities.html)). Here, we use the default Tensorflow TPC:"
]
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@
"In order to evaulate our generated images, we will use them to quantize the model using MCT's PTQ.This is referred to as **\"Zero-Shot Quantization (ZSQ)\"** or **\"Data-Free Quantization\"** because no real data is used in the quantization process. Next we will define configurations for MCT's PTQ.\n",
"\n",
"### Target Platform Capabilities (TPC)\n",
"MCT optimizes the model for dedicated hardware platforms. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html)). Here, we use the default Pytorch TPC:"
"MCT optimizes the model for dedicated hardware platforms. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform_capabilities.html)). Here, we use the default Pytorch TPC:"
],
"metadata": {
"collapsed": false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@
"source": [
"## Target Platform Capabilities (TPC)\n",
"In addition, MCT optimizes models for dedicated hardware platforms using Target Platform Capabilities (TPC). \n",
"**Note:** To apply mixed-precision quantization to specific layers, the TPC must define different bit-width options for those layers. For more details, please refer to our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html). In this example, we use the default PyTorch TPC, which supports 2, 4, and 8-bit options for convolution and linear layers."
"**Note:** To apply mixed-precision quantization to specific layers, the TPC must define different bit-width options for those layers. For more details, please refer to our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform_capabilities.html). In this example, we use the default PyTorch TPC, which supports 2, 4, and 8-bit options for convolution and linear layers."
],
"metadata": {
"collapsed": false
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@
"cell_type": "markdown",
"source": [
"## Target Platform Capabilities (TPC)\n",
"In addition, MCT optimizes the model for dedicated hardware platforms. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform.html)). Here, we use the default Pytorch TPC:"
"In addition, MCT optimizes the model for dedicated hardware platforms. This is done using TPC (for more details, please visit our [documentation](https://sony.github.io/model_optimization/api/api_docs/modules/target_platform_capabilities.html)). Here, we use the default Pytorch TPC:"
],
"metadata": {
"collapsed": false
Expand Down

0 comments on commit 2e565f2

Please sign in to comment.