Which of the following statements about converting a TensorFlow model to TensorFlow Lite (TFLite) format is correct?
Think about what optimizations help models run faster and smaller on mobile devices.
TFLite conversion supports optimizations such as quantization, which reduces model size and speeds up inference on mobile devices. It does not require retraining, works on multiple platforms, and does not convert Python code.
Given a TFLite model that takes an input image of shape (1, 224, 224, 3) and outputs a tensor of shape (1, 1000), what does the output represent?
Consider typical classification model outputs and their shapes.
The output shape (1, 1000) means one image batch with 1000 class scores, typical for classification tasks like ImageNet.
You want to deploy a computer vision model on iOS using Core ML. Which model architecture is best suited for mobile deployment considering speed and size?
Think about models designed specifically for mobile and embedded devices.
MobileNetV2 uses depthwise separable convolutions to reduce size and computation, making it ideal for mobile deployment with Core ML.
When applying post-training quantization to a TensorFlow model before converting to TFLite, which hyperparameter setting most directly affects the model's size reduction?
Quantization reduces precision to shrink model size.
The bit-width used in quantization directly controls how much the model size shrinks; lower bit-width means smaller size.
You converted a TensorFlow model to Core ML but get an error when running inference: "Input shape mismatch: expected (1, 224, 224, 3) but got (3, 224, 224)". What is the most likely cause?
Check if the input tensor includes the batch size dimension.
Core ML models typically expect a batch dimension. The error shows the input lacks the batch size (1), causing the mismatch.