Inference
Learn how to use the ML library to perform inference.
We'll cover the following...
Now that we have a package, we’ll write a simple code to use the library to make predictions of iris species, given some data. The first step is to install the package in the environment where we perform inference. How this is done depends on the environment. One way is to use the pip
command as follows, assuming we’re in the pipeline’s top-level directory:
pip install dist/ml_pipeline-1.0.0-py3-none-any.whl
For the purpose of this lesson, we’ll assume that the library has been installed, and we’ll proceed to inference. During inference data is rarely, if ever, provided in the form of files. Typically, it’s streamed into the application that contains the prediction code. For tabular data, the input can be in the form of a dictionary. Here’s an example of the ...