This baseline project shows how to get the most out of Python on Cloudera Data Science Workbench.
Modify the default files to get started with your own project.
README.md
-- This project's readme in Markdown format.analysis.py
-- An example Python analysis script.cdsw-build.sh
-- A custom build script used for models and experiments. This will pip install our dependencies, primarily the scikit-learn library.fit.py
-- A model training example to be run as an experiment. Generates the model.pkl file that contains the fitted parameters of our model.predict.py
-- A sample function to be deployed as a model. Usesmodel.pkl
produced byfit.py
to make predictions about petal width.
- Click "Open Workbench".
- Launch a new Python session.
- Run
analysis.py
in the workbench.
- Click "Open Workbench".
- Run an experiment with
fit.py
as the input script. - Once the experiment is complete, save the
model.pkl
file to the project. - Deploy a model using
predict.py
. Specifypredict
as the input function.
For detailed instructions on how to run these scripts, see the documentation.