Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Sign up for free
Menu
Search
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Features
All features
Private URLs
Password Protection
Custom URLS
Scheduled publishing
Remove Branding
Restrict embedding
Deck Collections
Notes
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Explore
Featured decks
Featured speakers
Programming
Technology
Storyboards
Pricing
Search
Sign in
Sign up for free
Python Application Case
Search
Vicky Vernando Dasta
January 27, 2018
Programming
68
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Python Application Case
Python Workshop @ Kongkow IT 2018
Vicky Vernando Dasta
January 27, 2018
More Decks by Vicky Vernando Dasta
See All by Vicky Vernando Dasta
PYTHON 101
vickydasta
0
130
Other Decks in Programming
See All in Programming
AI Agent時代のリアーキテクチャ戦略と実践
hokaccha
9
5.2k
SONY CISC-NEWS NWS-1750 + NWB-225 フレームバッファの NetBSD/news68k ドライバ実装 / OSC2026Hiroshima
tsutsui
0
160
Security issues being discussed on Web Platforms
petamoriken
0
1.4k
JPUG勉強会 OSSデータベースの内部構造を理解しよう(第2回)
oga5
0
290
機械に任せるテスト、人が見るテスト ⽣成AIで引き直した、運⽤保守フェーズの線引き
dske104
0
110
モバイル交通系ICへのチャージ実例から考える、クロスプラットフォーム開発におけるiOS実機テスト設計とCI運用
yusuga
1
570
Omarchy Tokyo やると聞いて UMPC 買ってセットアップしてきた
mtsmfm
0
200
ゲームコントローラやキーボードのファームウェアをSwiftで書く
kishikawakatsumi
1
270
Starting & Sustaining Code-Based E2E Testing for Non-Coding QA Teams( #jasstniigata )
teyamagu
PRO
1
810
世界の中心で、AI(App Intents)をさけぶ ー App Intents中心設計の実践ガイド
touyou
0
740
大喜利で理解するLLM as a Judge / Understanding LLM-as-a-Judge through Ogiri
rockname
0
180
AI が書く Go コードの品質を劇的に向上させる Linter: “declscope”
mpyw
0
460
Featured
See All Featured
The Limits of Empathy - UXLibs8
cassininazir
1
690
技術選定の審美眼(2025年版) / Understanding the Spiral of Technologies 2025 edition
twada
PRO
120
120k
Public Speaking Without Barfing On Your Shoes - THAT 2023
reverentgeek
1
580
The agentic SEO stack - context over prompts
schlessera
0
950
HDC tutorial
michielstock
2
930
Organizational Design Perspectives: An Ontology of Organizational Design Elements
kimpetersen
PRO
1
840
[Rails World 2023 - Day 1 Closing Keynote] - The Magic of Rails
eileencodes
38
3k
ラッコキーワード サービス紹介資料
rakko
1
5.1M
For a Future-Friendly Web
brad_frost
183
10k
<Decoding/> the Language of Devs - We Love SEO 2024
nikkihalliwell
1
330
GitHub's CSS Performance
jonrohan
1033
470k
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
420
Transcript
PYTHON WORKSHOP HAFIZHAN: WEB APPLICATION WITH PYTHON FLASK VICKY: PYTHON
101 AND APPLICATION IN SECURITY & MACHINE LEARNING
Workshop repo github.com/vickydasta/kongkow-python
About • Student @ physics dept. UR • Research assistant
at photonic lab @ UR • Research interest: photonic, applied machine learning on raspberry pi system • Python user 2014-now
Python at a glance • Multipurpose • OOP (everything is
object) • Dynamic typing • Batteries included • Case sensitive
None
Things we can build computer vision search engine security tools
embedded system web services web application machine learning apps
Your First Python Code print “hello, world!” print(“hello, world!”)
Data Structure • Integer • Float • List • String
• Boolean • Dictionary • Tupple
Data Structure: list • Create an empty list • Add
an item into it • Access item • Remove some item fr = [] fr.append(“guava”) fr[0] fr.remove(“guava”)
Data Structure: tupple • Immutable array • Data are read-only
• Items in tupple can’t be deleted • Can’t add more data once it’s created fixed_data = (1, 2) fixed_data[0] # 1 fixed_data[0] = 1
Data Structure: dict • Named-list • Key-value user = {“name”
“vicky”, “age”: 21} user[“name”] user.keys() user.values() user = {name=“vicky”, age=21}
Control Flow In Python, there are: • if • elif
• else • for • while • continue • break
Control Flow: if if 1 > 0: print “1 larger
than 0”
Control Flow: if-else if 1 > 2: print “hola” else:
print “holi”
Control Flow: if-elif-else if 1 > 2: print “hola” elif
1 > 3: print “holu” else: print “holi”
Loop: for • for loop is for iterating over iterable
object • range function creates list which is iterable • in above case, the i is 0, 1, 2, ..., 99 on each iteration for i in range(100): print(i)
Looping: while • while Requires a condition in order to
start or terminate the loop (while-break) while True: print “hello!” N = 0 while N < 10: N += 1
Function: def • def is the keyword for creating function
def gravity_force(M, m, r): return 6.62e+12*(M*m)/r**2 Function keyword Returned value(s) arguments function name
Coding style in Python • Python uses indentation • 3
spaces or 1 tab for each scope • No brackets or semicolons!
Python Application Case: Machine Learning Security
Machine Learning: Security: Predict land price by its size Port
scanner
Sec: Port scanner • Door knocking analogy • Bruteforce
ML: Linear Regression • Linear model out = mx+b •
Scikit learn search for the m • so the predicted value can be close to y
ML: Datasets X (M2) Y ($ USD) 200 2000 250
3500 300 5000 378 5400 456 6500 680 8700 800 10000
ML: model training datasets model f(x)
ML: prediction new input predicted output Trained Model
ML: scikit-learn • Machine learning is difficult problem • Fortunately,
we have scikit-learn
Python resources • github.com/vinta/awesome-python