Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Numpy, the Python foundation for number crunching
Search
Data Science London
November 12, 2012
Technology
1
5k
Numpy, the Python foundation for number crunching
Talk by Didrik Pinte, MD at Enthought at Data Science London meetup 18/10/12
Data Science London
November 12, 2012
Tweet
Share
More Decks by Data Science London
See All by Data Science London
Semi-Supervised Anomaly Detection
datasciencelondon
0
860
Hacking the Rail: Ingesting, analysing & visualising realtime streaming data
datasciencelondon
1
47k
Stateful Data-Parallel Processing
datasciencelondon
0
47k
Semantic web warmed up: Ontologies for the IoT
datasciencelondon
0
110
IoT data ingestion pipelines and Clojure transducers
datasciencelondon
0
250
TrendCalculus: A data science for trends
datasciencelondon
1
48k
Data Science in Mobile Health
datasciencelondon
1
8.3k
Large-scale Recommender Systems on Just a PC (with GraphChi)
datasciencelondon
1
17k
Taming Graph Dynamics at Scale
datasciencelondon
0
8.1k
Other Decks in Technology
See All in Technology
プッシュ型子育てサービスを、先行プロジェクト実施自治体において開始します
govtechtokyo
0
220
統計的学習理論読み Chapter 1
kmatsui
3
570
沒想過的前端錯誤處理可能比你有做的還多
line_developers_tw
PRO
0
1.8k
技術広報経験0のEMがエンジニアブランディングをはじめてみた
coconala_engineer
1
130
.NETの非同期戦略とUnityとの相互運用
neuecc
2
2.4k
技育祭2024春 LT Finatextホールディングス
kevinrobot34
1
160
HoneycombとOpenTelemetryでオブザーバビリティに入門してみる
sumiren
2
140
LLM + RAG を使った SORACOM Support Bot の裏側の歴史
soracom
PRO
1
630
どう買う?Azure
kuniteru
1
190
事業部を超えた 開発生産性向上に挑戦する
kentakozuka
5
930
Evolutionary Optimization of Model Merging Recipes
fuyu_quant0
3
510
Vos logs méritent mieux que la config par défaut
lyrixx
2
110
Featured
See All Featured
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
113
18k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
111
35k
jQuery: Nuts, Bolts and Bling
dougneiner
57
7.1k
The Power of CSS Pseudo Elements
geoffreycrofte
58
4.9k
Unsuck your backbone
ammeep
660
56k
Optimizing for Happiness
mojombo
369
69k
Embracing the Ebb and Flow
colly
78
4.1k
Agile that works and the tools we love
rasmusluckow
323
20k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
1
3.3k
Faster Mobile Websites
deanohume
296
30k
Rails Girls Zürich Keynote
gr2m
91
13k
The Cult of Friendly URLs
andyhume
72
5.6k
Transcript
Numpy, the Python foundation for number crunching Didrik Pinte, Enthought
London Data Science meetup Monday 22 October 2012
Number crunching? •High-level api •Interactivity & visualization •Performance •Low-level access
Monday 22 October 2012
Evidence ? PyCuda PyTrilinos Joblib petsc4py PyAlgoTrade numpy-boost Clyther PyOpenGL
Monday 22 October 2012
Evidence ? PyCuda PyTrilinos Joblib petsc4py PyAlgoTrade numpy-boost Clyther PyOpenGL
Monday 22 October 2012
Why then? •The API ... •Simple but powerful memory model
•Open access to the data Monday 22 October 2012
Array data structure Monday 22 October 2012
Let’s look at the code! •Examples: – API / interactivity
– memory management with stride_tricks – pikos – extensions with talib –(joblib, memmap/multiprocessing, ipython //) Monday 22 October 2012
API / interactivity Monday 22 October 2012
Memory management 1 2 3 4 5 6 7 8
9 10 1 2 3 4 2 3 4 5 3 4 5 6 12 11 = 4 5 6 7 5 6 7 8 6 7 8 9 7 8 9 10 8 9 10 11 ... Monday 22 October 2012
Memory management 1 2 3 4 5 6 7 8
9 10 1 2 3 4 2 3 4 5 3 4 5 6 12 11 = Shape 12, Strides 8, Shape 9,4, Strides 8,8 4 5 6 7 5 6 7 8 6 7 8 9 7 8 9 10 8 9 10 11 ... Monday 22 October 2012
Memory management - pikos Monday 22 October 2012
Memory management - chaco Monday 22 October 2012
Low level access %timeit talib.moving_average(adj_close, optInTimePeriod=5) 100000 loops, best of
3: 7.67 us per loop %timeit as_strided(adj_close, shape=(len(adj_close)-4, 5), strides=(8, 8)).mean (axis=1) 10000 loops, best of 3: 28.2 us per loop Monday 22 October 2012
Conclusion •It’s obvious, no? Monday 22 October 2012
Q & A ? Monday 22 October 2012