Escolar Documentos
Profissional Documentos
Cultura Documentos
Machine Learning
http://playground.tensorflow.org_maXbox2 3
https://www.springboard.com/blog/data-mining-python-tutorial/
3
Topic IRIS Classify Task
4
https://sebastianraschka.com/images/blog/2015/principal_component_analysis_files/iris.png
https://www.springboard.com/blog/data-mining-python-tutorial/ 4
Regression and Correlation
@C:\maXbox\EKON22\EKON22_scripts\EKON22_REG_2.py
CASSANDRA System
2. C:\maXbox\mX46210\ntwdblib.dll\UnsharpDetector-master\UnsharpDetector-master\inference_gui.py
5
From Correlation to 4 Dim Cluster
Finding the question is often more important than finding the answer - John Tukey
https://www.soovle.com/ 6
https://answerthepublic.com/reports/ 6
Clustering from module import class
0 1 2 3 4
5 6 37 81 9
@C:\maXbox\EKON22\EKON22_scripts\EKON22_CLU_3.py
CASSANDRA System
7
GEO
Cluster
Story
An agent or probe that collects threat data from the security sensor and correlation
middleware. A console and associated database for managing the solution and its alerts. 8
https://www.esecurityplanet.com/views/article.php/1501001/Security-Threat-Correlation-The-Next-Battlefield.htm
8
IRIS Classification Concept
0 1 2 3 4
5 6 4 3 4
from sklearn import datasets, tree
iris = datasets.load_iris()
clf = tree.DecisionTreeClassifier()
CASSANDRA System
clf = clf.fit(iris.data, iris.target)
y_pred = clf.predict(iris.data)
10
10
IRIS Decision Tree
11
@C:\maXbox\EKON22\EKON22_scripts\EKON23_DET_5.py
11
MongoDB My Cluster sacred.runs & completed
CASSANDRA System
12
Task II
13
13
What's behind test ? (backend pattern, crossentropy)
60000/60000 [==============================] - 426s 7ms/step - loss: 0.4982 - acc: 0.8510 -
val_loss: 0.0788 - val_acc: 0.9749
Using TensorFlow backend.
INFO - MNIST-Convnet4 - Result: 0.9749
INFO - MNIST-Convnet4 - Completed after 0:07:27
Test loss: 0.0788029053777
Test accuracy: 0.9749
59392/60000 [============================>.] - ETA: 5s - loss: 0.0571 - acc: 0.9829
59520/60000 [============================>.] - ETA: 3s - loss: 0.0572 - acc: 0.9829
59648/60000 [============================>.] - ETA: 2s - loss: 0.0572 - acc: 0.9829
59776/60000 [============================>.] - ETA: 1s - loss: 0.0572 - acc: 0.9829
59904/60000 [============================>.] - ETA: 0s - loss: 0.0573 - acc: 0.9829
60000/60000 [==============================] - 513s 9ms/step - loss: 0.0573 - acc:
0.9829 - val_loss: 0.0312 - val_acc: 0.9891
INFO - MNIST-Convnet4 - Result: 0.9891
INFO - MNIST-Convnet4 - Completed after 0:33:28
Test loss: 0.0311644290059
Test accuracy: 0.9891 14
14
What's behind code ? (Classification Summary)
16
What's behind Python: PIP3 Install
pip3 install sacred
Collecting sacred
Downloading
https://files.pythonhosted.org/packages/2d/86/7be3af
a4d4c1c0c76a5de03e5ff779797ab2654e377685255c11c13c0e
a5/sacred-0.7.3-py2.py3-none-any.whl (82kB)
Collecting pymongo
Downloading
https://files.pythonhosted.org/packages/46/39/b9bb7fed3e3a0ea621a1
512a938c105cd996320d7d9894d8239ca9093340/pymongo-3.6.1-cp36-cp36m-
win_amd64.whl (291kB)
100% |¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦| 296kB 728kB/s
Installing collected packages: pymongo
Successfully installed pymongo-3.6.1
https://github.com/pinae/Sacred-MNIST/blob/master/train_convnet.py 17
17
Machine Learning Process Chain
http://www.softwareschule.ch/examples/machinelearning.jpg
https://maxbox4.wordpress.com/code/
18
https://www.kaggle.com/ v ( a, j ) v(b, j )
similarity of doc a to doc b = sim(a, b)
word i v ( a, j ' )
j'
2
(b, j ' )
v
j'
2
A'B'
CASSANDRA System
19
Double Trouble with ML → https://stats.stackexchange.com/
File
Stackexchange,
"C:\Users\max\AppData\Local\Programs\Python\Pyt
THE TEST Stackoverflow
Status Description
OVERVIEW
hon36\lib\site-
QUEUED
The run was just packages\sklearn\metrics\cluster\unsupervised.py",
queued line 254, in calinski_harabaz_score
and not run yet
RUNNING intra_disp += np.sum((cluster_k - mean_k) ** 2)
Currently running (but see below)MemoryError
COMPLETED
File "C:\Users\max\AppData\Local\Programs\Python\Python36\lib\site-
Completed successfully
packages\sklearn\metrics\cluster\unsupervised.py", line 254, in
calinski_harabaz_score
intra_disp += np.sum((cluster_k - mean_k) ** 2) MemoryError
FAILED
The run failed due to an exception No. of URLs removed 76,732,515
INTERRUPTED + No. of robots.txt 3,675,634
The run was cancelled with a requests
KeyboardInterrupt
TIMED_OUT - No. of excludedURLs 3,050,768
The run was aborted using a TimeoutInterrupt = No. of HTTP requests 77,357,381
[custom]
A custom py:class: HTTP requests not 1,763850
~sacred.utils.SacredInterrupt respond
20
occurred
20
QUESTIONS ?
17:45 - 18:30
Machine Learning II
Art. Neural Network
21