概念
Types of inferencing
Real-time, serverless, asynchronous and batch: pick by speed, size and traffic.
本课尚未翻译,暂以英文显示。
Real-time
- Answers
- At once
- Choose it for
- Steady traffic, low delay
Serverless
- Answers
- At once
- Choose it for
- Uneven traffic, idle gaps
Asynchronous
- Answers
- Later, from a queue
- Choose it for
- Large inputs, long jobs
Batch
- Answers
- After the whole job
- Choose it for
- Scoring many records offline
| Type | Answers | Choose it for |
|---|---|---|
| Real-time | At once | Steady traffic, low delay |
| Serverless | At once | Uneven traffic, idle gaps |
| Asynchronous | Later, from a queue | Large inputs, long jobs |
| Batch | After the whole job | Scoring many records offline |
1 / 2
Real-time
- Answers
- At once
- Choose it for
- Steady traffic, low delay
Serverless
- Answers
- At once
- Choose it for
- Uneven traffic, idle gaps
Asynchronous
- Answers
- Later, from a queue
- Choose it for
- Large inputs, long jobs
| Type | Answers | Choose it for |
|---|---|---|
| Real-time | At once | Steady traffic, low delay |
| Serverless | At once | Uneven traffic, idle gaps |
| Asynchronous | Later, from a queue | Large inputs, long jobs |
2 / 2
Batch
- Answers
- After the whole job
- Choose it for
- Scoring many records offline
| Type | Answers | Choose it for |
|---|---|---|
| Batch | After the whole job | Scoring many records offline |
是什么
Real-time inference answers one request at once, in milliseconds. The model runs all the time, ready to reply. Use it when a person or app waits, such as a fraud check at checkout.
Serverless inference also answers at once, but you pay only while it handles requests. It suits traffic that is uneven or has long idle gaps. A first request after an idle time can be slower.
Asynchronous inference queues large requests or long jobs and returns the result later. Batch inference runs a whole dataset in one go, with no one waiting, such as scoring all customers overnight. SageMaker AI offers all four ways; see Amazon SageMaker AI.
要记住
- Real-time: instant answers, model always running.
- Serverless: instant answers, pay only when used, good for idle time.
- Asynchronous: large payloads or long processing, result comes later.
- Batch: a whole dataset at once, no one waits. SageMaker AI calls this a batch transform job.
要记住
- Choose by latency, payload size and how busy the traffic is.
考试中
- “Predictions in milliseconds for a live app” points to real-time inference.
- “Unpredictable traffic with long idle periods” points to serverless inference.
- “Large input and the result may wait” points to asynchronous inference.
- “Score a whole dataset overnight” points to batch inference.
别和这些弄混
- Training, inferencing, bias and fitTraining builds a model from data. Inferencing uses it. Bias and fit tell you how well it learned.
- Models in productionUse a model through a managed API or host it yourself.
Amazon SageMaker AIBuild, train and deploy your own machine learning models on managed infrastructure.