ExamGecko
Question list
Search
Search

List of questions

Search

Related questions











Question 36 - Professional Machine Learning Engineer discussion

Report
Export

You work for a social media company. You need to detect whether posted images contain cars. Each training example is a member of exactly one class. You have trained an object detection neural network and deployed the model version to Al Platform Prediction for evaluation. Before deployment, you created an evaluation job and attached it to the Al Platform Prediction model version. You notice that the precision is lower than your business requirements allow. How should you adjust the model's final layer softmax threshold to increase precision?

A.
Increase the recall
Answers
A.
Increase the recall
B.
Decrease the recall.
Answers
B.
Decrease the recall.
C.
Increase the number of false positives
Answers
C.
Increase the number of false positives
D.
Decrease the number of false negatives
Answers
D.
Decrease the number of false negatives
Suggested answer: B

Explanation:

Precision and recall are two common metrics for evaluating the performance of a classification model. Precision measures the proportion of positive predictions that are correct, while recall measures the proportion of positive examples that are correctly predicted. Precision and recall are inversely related, meaning that increasing one will decrease the other, and vice versa.The trade-off between precision and recall depends on the goal and the cost of the classification problem1.

For the use case of detecting whether posted images contain cars, precision is more important than recall, as the social media company wants to minimize the number of false positives, or images that are incorrectly labeled as containing cars. A high precision means that the model is confident and accurate in its positive predictions, while a low recall means that the model may miss some positive examples, or images that actually contain cars. The cost of missing some positive examples is lower than the cost of making wrong positive predictions, as the latter may affect the user experience and the reputation of the social media company.

The softmax function is a function that transforms a vector of real numbers into a probability distribution over the possible classes. The softmax function is often used as the final layer of a neural network for multi-class classification problems, as it assigns a probability to each class, and the class with the highest probability is chosen as the prediction. The softmax function is defined as:

softmax (x_i) = exp (x_i) / sum_j exp (x_j)

where x_i is the input value for class i, and softmax (x_i) is the output probability for class i.

The softmax threshold is a parameter that determines the minimum probability that a class must have to be chosen as the prediction. For example, if the softmax threshold is 0.5, then the class with the highest probability must have at least 0.5 to be selected, otherwise the prediction is none.The softmax threshold can be used to adjust the trade-off between precision and recall, as a higher threshold will increase the precision and decrease the recall, while a lower threshold will decrease the precision and increase the recall2.

For the use case of detecting whether posted images contain cars, the best way to adjust the model's final layer softmax threshold to increase precision is to decrease the recall. This means that the softmax threshold should be increased, so that the model will only make positive predictions when it is highly confident, and avoid making false positives. By increasing the softmax threshold, the model will become more selective and accurate in its positive predictions, and improve the precision metric. Therefore, decreasing the recall is the best option for this use case.

Precision and recall - Wikipedia

How to add a threshold in softmax scores - Stack Overflow

asked 18/09/2024
Maurice Sterkenburg
35 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first