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
QuadTrees with OCaml
Search
Paul Chobert
October 16, 2011
Research
0
750
QuadTrees with OCaml
Paul Chobert
October 16, 2011
Tweet
Share
More Decks by Paul Chobert
See All by Paul Chobert
SCNF 311
barodeur
0
91
Stage @Novelys - été 2011
barodeur
1
120
Other Decks in Research
See All in Research
音声処理ツールキットESPnetの現在と未来
kanbayashi1125
2
540
時系列解析と疫学
kingqwert
2
920
HP (Hitto Point: 筆頭ポイント)
tanichu
0
650
精神疾患患者のアクティビティデータを利用したリハビリテーションのためのシステムに関する研究
comfortdesignlab
0
140
20240127_熊本から今いちど真面目に都市交通~めざせ「車1割削減、渋滞半減、公共交通2倍」~ 全国路面電車サミット2024宇都宮
trafficbrain
1
650
メタ動画データセットによる動作認識の現状と可能性
yuyay
0
180
Bridging Continuous and Discrete Spaces: Interpretable Sentence Representation Learning via Compositional Operations
rudorudo11
0
160
第4回ナレッジグラフ勉強会:ISWC2023論文読み会
kg_wakate
1
200
Ground Metric Learning with applications in genomics
gpeyre
0
360
Azure Arc-enabled Serversを利用した ハイブリッド・マルチクラウド環境の管理 / Managing Hybrid Multi-cloud Environments with Azure Arc-enabled Servers
nttcom
0
210
[ICLR'24] Towards Assessing and Benchmarking Risk-Return Tradeoff of OPE
harukakiyohara_
0
180
プロシェアリング白書2024_PROSHARING_REPORT_2024
circulation
0
610
Featured
See All Featured
[RailsConf 2023 Opening Keynote] The Magic of Rails
eileencodes
9
8.3k
Statistics for Hackers
jakevdp
789
220k
WebSockets: Embracing the real-time Web
robhawkes
59
7k
Designing with Data
zakiwarfel
95
4.8k
GitHub's CSS Performance
jonrohan
1023
450k
Agile that works and the tools we love
rasmusluckow
324
20k
Pencils Down: Stop Designing & Start Developing
hursman
117
11k
Documentation Writing (for coders)
carmenintech
59
3.9k
It's Worth the Effort
3n
180
27k
Imperfection Machines: The Place of Print at Facebook
scottboms
258
12k
個人開発の失敗を避けるイケてる考え方 / tips for indie hackers
panda_program
60
14k
Large-scale JavaScript Application Architecture
addyosmani
503
110k
Transcript
QuadTrees Projet IAP1 Paul Chobert 26 novembre 2010 let presentation
=
QuadTrees • Arbres
QuadTrees • Arbres • Partition d’espaces
QuadTrees • Arbres • Partition d’espaces • Compression d’images
QuadTrees • Arbres • Partition d’espaces • Compression d’images •
Algorithme en O(ln )
Les PQuadTrees
Collections de points Comment stocker des points efficacement?
Collections de points Comment stocker des points efficacement? • Avec
des listes let points = [(0,1);(0,4);(1,1);(1,3);(3,4);(4,3)]
Collections de points Comment stocker des points efficacement? • Avec
des listes let points = [(0,1);(0,4);(1,1);(1,3);(3,4);(4,3)] • Avec des matrices false true false false true false true false true false false false false false false false false false false true false false false true false
Avec des listes Recherche de point
Avec des listes Recherche de point 1 let rec recherche
p l= 2 match l with 3 [] -> false 4 | t::q -> 5 p=t || p>t && (recherche p q);;
Avec des listes Recherche de point • Utilisation mémoire faible…
1 let rec recherche p l= 2 match l with 3 [] -> false 4 | t::q -> 5 p=t || p>t && (recherche p q);;
Avec des listes Recherche de point • Utilisation mémoire faible…
• … mais algorithme pas efficace. 1 let rec recherche p l= 2 match l with 3 [] -> false 4 | t::q -> 5 p=t || p>t && (recherche p q);;
Avec des matrices Recherche de point
Avec des matrices Recherche de point 1 let recherche (x,y)
m= 2 m.(x).(y);;
Avec des matrices Recherche de point • Recherche de point
presque instantanée… 1 let recherche (x,y) m= 2 m.(x).(y);;
Avec des matrices Recherche de point • Recherche de point
presque instantanée… • … mais utilisation mémoire catastrophique. 1 let recherche (x,y) m= 2 m.(x).(y);;
LA PUISSANCE EST DANS LES ARBRES
LA PUISSANCE EST DANS LES ARBRES
LA PUISSANCE EST DANS LES ARBRES (ln ()) & empreinte
mémoire faible
Démo
-1 1 3 5 7 9 11 1 10 100
1000 2000 3000 4000 5000 6000 7000 8000 9000 10000 11000 12000 13000 14000 15000 20000 30000 Temps en secondes performances PQuadTree Listes
None
R Q U A D T R E E S
Codage des RQuadTrees
Codage des RQuadTrees
Codage des RQuadTrees [0;1;0;0;1;1;1;0;1;0; 1;0;1;1;0;1;1;1;0;1;0 ;1;1]
- Lecture séquentiel du codage
- Lecture séquentiel du codage 1::0::reste -> q = push
(Uni Blanc) q | 1::1::reste -> q = push (Uni Noir) q | 0::reste -> q = push (RQ(Vide,Vide,Vide,Vide)) q | [] -> q
- Lecture séquentiel du codage 1::0::reste -> q = push
(Uni Blanc) q | 1::1::reste -> q = push (Uni Noir) q | 0::reste -> q = push (RQ(Vide,Vide,Vide,Vide)) q | [] -> q =>
Conclusion ;;