What Goes Wrong with Language Definitions and How to Improve the Situation
Moving Objects and Spatial Data Computing
1. Moving Objects and
Spatial Data Computing
(이동체 및 공간 데이터 컴퓨팅 연구 동향)
2017. 09. 28
Kwang Woo NAM
kwnam@kunsan.ac.kr
Kunsan National University
This research was supported by a Grant (14NSIP‐B080144‐01) from National Land Space Information
Research Program funded by Ministry of Land, Infrastructure and Transport of Korean government. 2017.09.28 KAIST 조천식녹색교통대학원 발표자료
2. 2
Who
남광우 교수/ 국립 군산대학교
‐ 군산대 컴퓨터정보통신공학부(2004‐현재)
‐ 미래형자동차 R&D 전문인력양성사업단(2017‐)
{ KEA, 군산대, 한양대, 충북대, 인하대, 부품연}
‐ 前 ETRI 텔레매틱스연구단 선임연구원(2001‐2004)
‐ U. of Minnesota Visiting Scholar(2015‐2016)
Projects
• 국토해양부, 공간정보 S/W활용을 위한 오픈소스 가공기술 개발(14‐19) : PostTrajectory
• NRF, 소셜 미디어 스트림 기반 공간 지식의 연속 마이닝(13‐16): SKSpark, SpatialTajo
• ETRI, 시멘틱 공간정보 서비스 프레임워크 및 구조 분석(10)
• 국토해양부, U‐GIS 국토정보 컨텐츠 서비스 요소 기술 연구(07‐11)
• NRF, geoSensor 센서 스트림 기반 점진적 온라인 패턴 마이닝 기법 연구(09‐12)
• NRF, GeoSensor Network를 위한 효율적인 공간 센서 스트림 죠인 및 집계처리 기법 연구(06‐07)
• NRF, 상황정보 기반의 Networked GeoVision 기술 개발(08‐11) : GeoVIsion
5. Introduction
공간 데이터
뉴미디어 공간정보 콘텐츠
공간 정보
공간정보 Spectrum의 확대
2D Vector
RS Data
2.5D Data DEM Data
LBS/TelematicsGeoERPWeb GIS
MultiSensor
Smart Phone
Real 3D Data 360 Panorama
Video+GPS
(blackbox)
Game,Edu,…
Closed Box(Public Sector)
Open Box( Enterpise Sector)
Shared Box(People Sector)
Sony Camera
(GPS+Pano) iWatch
Google Glass
GoPro
• Evolutions of Spatial Data/Information
6. Introduction
• 일반적인 공간좌표 및 POI 등의 공간 정보와 웹 문서, 도서, 사진,
동영상, 음성 등의 미디어가 결합된 공간정보 컨텐츠들의 등장
• 예) GoPro, PointCloud, 차량 블랙박스, 360 파노라마, 구글 글래스
GeoTagged Photo(Panoramio) 360 Panorama(StreetView)
Car Blackbox Video 자율주행차 PointCloud(LiDAR)
7. 7
• Converging into Spatial Data
Introduction
GNSS - 무선데이터통신망을
이용한 정밀위치정보제공
- 차량항법, 교통정보 제공
GIS SIIS
ITS
- 정밀 기준점 위치정보에
의한 영상정보 정확도 향상
- GPS 기지국 구축적지 선정
- 차량용 네비게이션 정보제공
- 교통주제도 구축 및 계량적
분석 기술제공
- 교통시설물 관리 및 IT기반
운영기술 제공
- 대용량 공간정보
자동수정 갱신
- 영상지도 제작
- 측량기술 및 관련기술
(위성삼각측량, WGS84)제공
- 실시간 Mobile GIS응용기술
- 영상기반 교통정보
수집기술제공
- 고 정밀 영상검지
시스템 구축
출처 : ETRI
23. 23
• PostGIS
• PostgreSQL Spatial Extension
• 경부 고속도로와 Cross하는 도로를 검색하라
• SELECT gid, name FROM bc_roads
WHERE ST_Crosses( the_geom, ST_GeomFromText(‘..’, 3005) );
• 대전시내안의 도로 총 길이를 구하라
• SELECT Sum( ST_Length( the_geom ) ) / 1000 AS km_roads
FROM bc_roads;
Spatial Database Systems
ST_Intersects(G1,G2)
ST_Contains(G1,G2)
ST_Within(G1,G2)
ST_Touches(G1,G2)
ST_DWithin(G1,G2,D)
24. 24
• pgRouting
• Routing function extension to PostGIS
• example page
• New York Bike Map : http://www.ridethecity.com/
Spatial Database Systems
SELECT * FROM pgr_dijkstra('
SELECT gid AS id,
source,
target,
cost_s / 3600 * 100 AS cost,
reverse_cost_s / 3600 * 100 AS
reverse_cost
FROM ways',
13009, 3986);
36. 36
• Rowkey로서의 GeoHash
• 지오해시가 로우키를 위한 최적의 선택인 이유
① 계산하기 쉽다
② 접두사가 최근접 이웃을 발견하는데 중요한 역할을 하기 때문
• 단점 : 접두사의 정확도와 경계값 문제
Spatial Big Data : Micro Blogs
38. 38
• Finding Home/Visitor
• Finding Spatial Words
Spatial Big Data : Micro Blogs
(mid, userid, x, y,
time, {word,…}) (<userid,geoid>, mid)
Map Shuffle
(<userid,geoid>, {mid,
mid, …})
Reduce
(<userid,geoid>, n)
(mid, userid, x, y,
time, {word,…}) (<geoid, word>, mid)
(<geoid, word>, mid)
(<geoid, word>, mid)
Map Shuffle
(<geoid, word>,{mid,
mid, …})
Reduce
(<geoid, word>, n)
39. 39
• SpatialHadoop
• 하둡에 공간 연산자를 지원하기 위하여 개발
• MapReduce를 이용하여 공간 연산자를 처리
• 2레벨 방식의 인덱스 이용
• Grobal index : 그리드 파일
• Local index : R‐tree
Spatial Big Data : Systems
Ahmed Eldawy, Mohamed F. Mokbel:
SpatialHadoop: A MapReduce framework for spatial data. ICDE 2015: 1352‐1363
40. 40
• Hadoop‐GIS
• HiveSP: 공간 데이터 웨어하우징 시스템
• 공간 분할, 공간 질의 엔진을 포함
• 2레벨 인덱스 사용
Spatial Big Data : Systems
Ablimit Aji, Fusheng Wang, Hoang Vo, Rubao Lee, Qiaoling Liu, Xiaodong Zhang, Joel H. Saltz:
Hadoop‐GIS: A High Performance Spatial Data Warehousing System over MapReduce. PVLDB 6(11): 1009‐1020 (2013)
41. 41
• Spark : In‐memory Computing
• GeoSpark
• Spark의 RDD를 SpatialRDD로 변형하여 공간 연산을 지원
• 2레벨 인덱스 사용
• 지역 인덱스를 메모리에 상주 시키고 질의를 수행
Spatial Big Data : Systems
Jia Yu, Jinxuan Wu, Mohamed Sarwat:
GeoSpark: a cluster computing framework for processing large‐scale spatial data. SIGSPATIAL/GIS 2015: 70:1‐70:4
42. 42
• SpatialSpark
• GPU에서 사용하는 공간 색인 및 공간 조인을 위한
CUDA/Thrust 구현을 참고하여 개발
• Scala의 벡터/콜렉션 함수가 지원하는 병렬 기본 요소 활용
• JTS 라이브러리 사용
• 공간 조인에 대한 성능을 비교 분석할 때 사용
• LocationSpark
• Query Scheduler
• 데이터가 한쪽으로 몰려 있는 곳의 통신 오버헤드를 완화하기 위
하여 각 파티션의 통계정보를 수집하여 파티션을 다시 분할
• Query Executor
• 특정 쿼리 평가를 실행하여 질의가 인덱스를 사용해야 하는지 여
부를 판단
Spatial Big Data : Systems
SpatialSpark : http://simin.me/projects/spatialspark/
LocationSpark : MingJie Tang, Yongyang Yu, Qutaibah M. Malluhi, Mourad Ouzzani, Walid G. Aref:
LocationSpark: A Distributed In‐Memory Data Management System for Big Spatial Data. PVLDB 9(13): 1565‐1568 (2016)
43. 43
• SKSpark : Spatial Keyword Spark
• First Spatial Keyword Big Data System
• BRQ
• 사용자가 질의 영역과 키워드를 입력하면 질의 영역에 해당되는 모
든 객체 중 키워드를 모두 포함하는 객체를 검색
• ,
• = 질의 단어
• = 질의 범위
• . ∩ . ∈ ∩ . ∩ . ∈
• BkQ
• 사용자가 질의 위치와 검색 단어를 입력하면 검색 단어를 모두 포함
하는 문서들 중 사용자의 위치와 가장 가까운 순서대로 k개를 검색
• , ,
• Spatial‐Keyword In‐memory Indexing
Spatial Big Data : Systems
54. 54
Trajectory Queries
• Queries
• Spatial Queries
• KAIST에 있었던 차량은?
• Spatio‐temporal Queries
• 오늘 7am‐8am 사이에 KAIST를 지나간 차량
은?
• Moving Objects Queries
• x지점 10m 이내로 지나간 차량은?
• 서로 10m 이내로 스쳐간 차량들은?
• 1시간 이상 KAIST에 머문 차량은?
• MO Mining Queries
• 두 대 이상 함께 움직인 차량들은(flock)?
55. 55
Trajectory Queries
• Range Queries
• k‐NN Queries
Yu Zheng, Trajectory Data Mining : An Overview, ACM Trans. on Intelligent System and Technology, Sept. 2015
56. 56
Trajectory Queries
• k‐NN Trajectory Queries
• 예 ) Car Pool App
• Find similar trajectory cars with my trajectory
Yu Zheng, Trajectory Data Mining : An Overview, ACM Trans. on Intelligent System and Technology, Sept. 2015
57. 57
Moving Objects Indexing
• Indexing Moving Objects
• 3DR‐Tree for Historical Trajectory Data
• Historical trajectories are represented by their three‐dimensional
MBB(Minimum Bounding Box)
Time
Mohamed F. Mokbel, Thanaa M. Ghanem, Walid G. Aref: Spatio‐Temporal Access Methods. IEEE Data Eng. Bull. 26(2): 40‐49 (2003)
Long‐Van Nguyen‐Dinh, Walid G. Aref, Mohamed F. Mokbel: Spatio‐Temporal Access Methods: Part 2 (2003 ‐ 2010). IEEE Data Eng. Bull. 33(2): 46‐55 (2010)
58. 58
Moving Objects Indexing
• Indexing Moving Objects
• Multi‐version Indexing for Historical Trajectories
• Maintain an R‐tree for each time instance
• R‐tree nodes that are not changed across consecutive time instances
are linked together
Timestamp 1Timestamp 0
3D‐R‐tree
Mohamed F. Mokbel, Thanaa M. Ghanem, Walid G. Aref: Spatio‐Temporal Access Methods. IEEE Data Eng. Bull. 26(2): 40‐49 (2003)
Long‐Van Nguyen‐Dinh, Walid G. Aref, Mohamed F. Mokbel: Spatio‐Temporal Access Methods: Part 2 (2003 ‐ 2010). IEEE Data Eng. Bull. 33(2): 46‐55 (2010)
59. 59
Moving Objects Indexing
• TB‐Tree : Trajectory Bundle Tree
• Hybrid index structure which preserves trajectories
• A predominant trajectory index structure for Euclidean
spaces
• Fast access to the trajectory information of moving objects
Dieter Pfoser, Christian S. Jensen, Yannis Theodoridis:
Novel Approaches to the Indexing of Moving Object Trajectories. VLDB 2000: 395‐406
60. 60
Moving Objects Indexing
• Indexing Moving Objects for Current Position Queries
• Focus Time : Now
• Features
• Frequent Insertion of New Data
• Continuous Queries about NOW data
• Example
• A 지역에 현재 있는 차의 수는?
• 현재 x 지점 근처에 가장 가까이 있는 차량 3대는?
• Problems
• 전통적인 R‐tree는 frequent update에 느림
62. 62
Moving Objects Indexing
• The Time‐parameterized R‐tree (TPR‐tree)
• Minimum bounding rectangles (MBR)
• Velocity bounding rectangles (VBR)
• MBR&VBR은 차량의 속도가 유지되는 한 동일한 MBR 안에
유지 될 수 있음을 보장함으로서 update를 최소화
Simonas Saltenis, Christian S. Jensen, Scott T. Leutenegger, Mario A. López:
Indexing the Positions of Continuously Moving Objects. SIGMOD Conference 2000: 331‐342
64. 64
Moving Objects Indexing
• Indexing on Road Network
• FNR‐Tree : Fixed Network R‐tree
• MON‐Tree : Moving Objects on Network
FNR‐Tree : E. Frentzos. Indexing objects moving on fixed networks. SSTD, 2003.
MON‐tree : Victor Teixeira de Almeida, et. al, Indexing the Trajectories of Moving Objects in Networks. GeoInformatica 9(1), 2005
R‐tree
for
Network
R‐tree
for
MO
66. 66
Moving Objects Patterns
• Region of Interest(ROI) : Static ROI
• Fixed pre‐defined regions
• Find frequent visited regions
A
B
C
time
67. 67
Moving Objects Patterns
• Region of Interest(ROI) : Dynamic ROI
• Spatial Clustering and Labeling
• Find frequent visited regions
cluster(x1,y1)
cluster(x2,y2)
time
68. 68
Moving Objects Patterns
• Moving Together Patterns
• Flock
• 특정 Region r내에서 m 개체이상이 같은 방향으로 움직임
• Leadership
• 가장 먼저 움직인 객체
• Convergence
• m 개체 이상이 같은 방향으로
• Encounter
• r내에서 만나는 지역
[37] J. Gudmundsson and M.V. Kreveld. 2006. Computing longest duration flocks in
trajectory data. In Proceedings of the 14th Annual ACM International Symposium on
Advances in Geographic Information Systems. ACM, 35‐42.
[38] J. Gudmundsson, M.V. Kreveld, and B. Speckmann. 2004. Efficient detection of
motion patterns in spatio‐temporal data sets. In Proceedings of the 12th Annual
ACM International Symposium on Advances in Geographic Information Systems.
ACM, 250–257.
69. 69
Moving Objects Patterns
• Moving Together Patterns
• Convoy
• min consecutive timestamps together
H. Jeung, M. Yiu, X. Zhou, C. Jensen, and H. Shen. 2008. Discovery of convoys in
trajectory databases. Proceedings of the VLDB Endowment 1, 1, 1068–1080.
70. 70
Moving Objects Patterns
• Moving Together Patterns
• Swarm
• min timestamps together
Z. Li, B. Ding, J. Han, and R. Kays. 2010. Swarm: Mining relaxed temporal moving
object clusters. Proceedings of the VLDB Endowment 3, 1-2, 723–734.
71. 71
Moving Objects Patterns
• Trajectory Clustering
• A Partition‐and‐Group Framework
J. G. Lee, J. Han, and K. Y. Whang. 2007. Trajectory clustering: A partition‐and‐group framework.
In Proceedings of ACM SIGMOD Conference on Management of Data. ACM, 593‐604
72. 72
Moving Objects Patterns
• Trajectory Clustering
• A Partition‐and‐Group Framework
J. G. Lee, J. Han, and K. Y. Whang. 2007. Trajectory clustering: A partition‐and‐group
framework. In Proceedings of ACM SIGMOD Conference on Management of Data. ACM, 593‐
604
73. 73
Moving Objects Patterns
• Trajectory Class
• TraClass Algorithm
• Classify subtrajectories instead of whole trajectories
Jae‐Gil Lee, Jiawei Han, Xiaolei Li, and Hector Gonzalez, “TraClass: Trajectory Classification Using Hierarchical Region‐Based and
Trajectory‐Based Clustering”, Proc. 2008 Int. Conf. on Very Large Data Base (VLDB'08), Auckland, New Zealand, Aug. 2008
74. 74
Moving Objects Patterns
• Travel Recommendation
• Find the interesting locations and travel sequences from
trajectories
Y. Zheng, L. Zhang, Z. Ma, X. Xie, W.‐Y. Ma. 2011. Recommending friends and locations based on individual location history. ACM
Transaction on the Web 5, 1, 5‐44.
Y. Zheng, L. Zhang, X. Xie, W.‐Y. Ma. 2009. Mining interesting locations and travel sequences from GPS trajectories. In Proceedings of the
18th International Conference on World Wide Web. ACM, 791‐800.
113. 113
• 사람이 찍힌 사진을 검색하시오
• 특정 지역내에 사람이 찍힌 사진을 검색하시오
GeoPhoto Queries
SELECT count(*)
FROM DronePhotos
WHERE NumOfFaces(uriString) >0 OR NumOfCars( uriString ) > 0 ;
SELECT count(*)
FROM DronePhotos
WHERE ( NumOfFaces(uriString) >0 OR NumOfCars( uriString ) > 0 ) AND
ST_WITHIN( geom, ST_MakeEnvelope(191232, 243117,191232, 243119,312) );
121. GeoVideo : Moving Objects
• GPS Trajectory and GeoVideo의 분석과 모니터링
차량 3대
센서 데이터
비교 분석
122. 122
• MediaQ by USC
• GeoUGV : User‐Generated Mobile Video
• Since 2014
• MediaQ web: http://mediaq.usc.edu
Related Work
Ying Lu, Hien To, Abdullah Alfarrarjeh, Seon Ho Kim, Yifang Yin, Roger Zimmermann, and Cyrus Shahabi,GeoUGV: User‐Generated
Mobile Video Dataset with Fine Granularity Spatial Metadata, In the 7th ACM Multimedia Systems Conference (MMSys), Klagenfurt
am Worthersee, Austria, May 10‐13, 2016
Seon Ho Kim, Ying Lu, Giorgos Constantinou, Cyrus Shahabi, Guanfeng Wang, and Roger Zimmermann,MediaQ: Mobile Multimedia
Management System. In the conference of Multimedia Systems (MMSys), In the conference of Multimedia Systems (MMSys), pages:
224 ‐ 235, Singapore, March 19 ‐21, 2014
123. 123
• GeoVideoIndex by POSTECH
• GeoVideo
• MBTR : Minimum Bounding Tilted Rectangle
Related Work
Dongha Lee, Jinoh Oh, Woong-Kee Loh, Hwanjo Yu:
GeoVideoIndex: Indexing for georeferenced videos. Inf. Sci. 374: 210-223 (2016)