Skip to content

Commit e3cc097

Browse files
committed
Added commands to install Python environment for ksql-python
1 parent a7710e7 commit e3cc097

File tree

1 file changed

+13
-8
lines changed

1 file changed

+13
-8
lines changed

live-demo___python-jupyter-apache-kafka-ksql-tensorflow-keras.adoc

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,8 @@ This script assumes that all components like Zookeeper, Kafka, Connect, KSQL, Ju
77

88
== Starting backend services
99

10-
First we need to start a local Kafka ecosystem to use KSQL from the Jupyter notebook. We also start a generator to create a continous feed of streaming data.
10+
First we need to start a local Kafka ecosystem to use KSQL from the Jupyter notebook. We also need to create some test data:
11+
Either start a data generator to create a continous feed of streaming data or integrate with a file (via Kafka Connect). As this is not part of the ML related tasks, but just to get some test data into a Kafka topic, we do it outside of Jupyter:
1112

1213
[source,bash]
1314
----
@@ -74,23 +75,27 @@ Follow the steps in the notebook to run the demo.
7475

7576
== Jupyter / pip / conda commands
7677

77-
Some common commands for Jupyter, pip, conda to manage packages like ksql-python:
78+
Some common commands for Jupyter, pip, conda to manage Python packages like ksql-python:
7879

7980
[source,bash]
8081
----
8182
82-
pip info
83-
84-
pip install ksql
8583
8684
conda info
87-
85+
conda create --name ksql-python python=3.4 tensorflow ksql
8886
conda info --envs
87+
88+
// Add to .bash_profile
8989
source activate ksql-python
9090
91-
conda install tensorflow
91+
// Add Python packages
92+
conda install --name ksql-python tensorflow numpy pandas keras seaborn matplotlib scipy scikit-learn
93+
conda remove -n ksql scipy
9294
93-
conda remove -n ksql-server scipy
95+
conda install -n ksql-python pip
96+
pip info
97+
pip install ksql
98+
pip install pickle
9499
95100
tensorboard --logdir logs
96101
tensorboard --logdir=logs/keras-fraud

0 commit comments

Comments
 (0)