Extracting Commute Patterns for Customized Bus Service Area … · 2018-11-29 · SRC:...

2
SRC: Extracting Commute Patterns for Customized Bus Service Area Design Jing Lian Tsinghua-Berkeley Shenzhen Institute Shenzhen, China [email protected] ABSTRACT Customized bus (CB) services that operate between residential areas and work places during rush hours have surfaced in many cities to deal with traffic congestion problem. One major challenge of CB services is to design service areas based on user demands. To solve this problem, we extract commute patterns from large- scale taxi GPS data for CB service area design. We present a novel clustering algorithm that embeds origin and destination data to a low dimensional feature space, such that the resulting patterns satisfy both the needs of commuters and operators. The algorithm has been tested on both synthesized and real-world data. 1 INTRODUCTION Traffic congestion is a severe problem worldwide, with peak-hour congestion being the most frustrated issue for daily commuters. In 2014, approximately 59% delay is caused by peak-hour congestion which costs U.S. commuters extra 42-hour of travel time and 19- gallon of fuel waste averagely[10]. On-demand bus service companies like BRIDJ and GoGoBus allow users to submit their intended trips and optimize pick-ups, drop-offs and routes. Such services provide better riding experi- ence than traditional public transport. Compared with car-sharing services, CB that carries more people than shared cars would help re- duce peak-hour congestion even further[5]. Therefore, CB services can be beneficial to both commuters and the city traffic authorities. However, current design process for customized bus service areas still have some shortcomings. First, candidate routes can only be submitted manually by users; second, changing routes frequently is inconvenient for both operators and riders. Therefore, a data-driven approach that extracts stable, salient commute patterns is needed. Due to the ubiquity of GPS devices, large-scale taxi GPS datasets are frequently used in mobility pattern mining, which can reliably reflect the global repetitive commute demands[1]. In previous work of designing origination(O) and destination(D) service areas, [2] only considered hotness of pick-ups and drop-offs separately; [8] put OD relationship into consideration but broke it into segment- and-pair two-phase process, during which information can be lost. [7] used T-DBSCAN clustering method, which considered OD rela- tionships in one phase but has many design parameters to choose. In this paper, we propose a new method of customized bus service area design. The main contributions are: (1) We propose a new clustering method to embed high dimen- sional data into low dimensional feature for clustering, which is a generalized method for high dimensional data clustering. (2) We design a customized bus service area selection method that optimize both user convenience and resource cost. 2 ALGORITHM Our method is designed to satisfy the needs of both users and service operators. Users want to minimize their walking distances to bus stops; operators, on the other hand, want to maximize number of people on the same bus so that people originate from the same area should end around the same place. Formally, we define the service area design problem as follows: Given the origins X and destinations Y of N taxi trips during a given time-of-day, we want to find feature functions f : X R and д : Y R, such that (1) the intra-cluster weighted distance X and Y are minimized min f , д 1 2 i, j e −(f i f j ) 2 X i X j 2 2 + 1 2 i, j e −(д i д j ) 2 Y i Y j 2 2 (1) (2) the correlation between f (X ) and д( Y ) are maximized max f , д E[f (X )]=E[д(Y )]=0, E[f 2 (X )]=E[д 2 (Y )]=1 E[ f (X ) д( Y )] (2) In objective (1), 2-D data X and Y are embedded into 1-D feature f (X ) and д( Y ) so that data close to each other in the original high- dimensional space should be close to each other in the feature space. The distance between the original data points X i , X j is weighted by feature similarities w ( f i , f j ), which should have two properties, (1) w ( f i , f j )∈[0, 1], w ( f i , f j ) = 1 means the distance between X i , X j is fully considered while w ( f i , f j ) = 0 means not. (2) w ( f i , f j ) is monotonically decreasing over f = | f i f j | , as similarities between points decrease, the distance between the original points should be considered less. The exponential function is a good choice for weight w (·) which satisfies those two properties plus its advantage of fast convergence rate and simple derivative. Objective (2) uses HGR maximal correlation[9], the only depen- dence measure that satisfies Rényi’s seven postulates, to quantize the relationship between OD pairs. This formulation (1), (2) have several benefits. First, correlation term provides a tradeoff between walking distance and OD correla- tion. Second, f (·) and д(·) are real-valued and solving continuous optimization problem is easier than integer ones. Third, f (·) and д(·) can be treated as 1-D embedded feature for further clustering without the need to specify crucial parameters explicitly. Note that this formulation has a trivial solution, where clusters can be formed by individual points. We solve it by adding a data weighted regularization term [6] to reduce number of clusters. min f , д i, j (e −∥X i X j 2 | f i f j | + e −∥Y i Y j 2 |д i д j |) (3) Combining (1), (2) and (3) with parameters γ for correlation trade-off and λ for regularization trade-off. The final optimization problem is shown below. Although it is a non-convex optimization problem, it can be efficiently solved using projected gradient descent to converge. min f , д E[f ]=E[д]=0 E[f 2 ]=E[д 2 ]=1 1 2 i, j e −(f i f j ) 2 X i X j 2 2 + 1 2 i, j e −(д i д j ) 2 Y i Y j 2 2 γ i f i · д i + λ i, j (e −∥X i X j 2 e | f i f j | + e −∥Y i Y j 2 e |д i д j | )

Transcript of Extracting Commute Patterns for Customized Bus Service Area … · 2018-11-29 · SRC:...

Page 1: Extracting Commute Patterns for Customized Bus Service Area … · 2018-11-29 · SRC: ExtractingCommute Patterns for Customized Bus Service Area Design ... is a generalized method

SRC: Extracting Commute Patterns for Customized Bus Service Area Design

Jing LianTsinghua-Berkeley Shenzhen Institute

Shenzhen, [email protected]

ABSTRACTCustomized bus (CB) services that operate between residentialareas and work places during rush hours have surfaced in manycities to deal with traffic congestion problem. One major challengeof CB services is to design service areas based on user demands.To solve this problem, we extract commute patterns from large-scale taxi GPS data for CB service area design. We present a novelclustering algorithm that embeds origin and destination data toa low dimensional feature space, such that the resulting patternssatisfy both the needs of commuters and operators. The algorithmhas been tested on both synthesized and real-world data.

1 INTRODUCTIONTraffic congestion is a severe problem worldwide, with peak-hourcongestion being the most frustrated issue for daily commuters. In2014, approximately 59% delay is caused by peak-hour congestionwhich costs U.S. commuters extra 42-hour of travel time and 19-gallon of fuel waste averagely[10].

On-demand bus service companies like BRIDJ and GoGoBusallow users to submit their intended trips and optimize pick-ups,drop-offs and routes. Such services provide better riding experi-ence than traditional public transport. Compared with car-sharingservices, CB that carries more people than shared cars would help re-duce peak-hour congestion even further[5]. Therefore, CB servicescan be beneficial to both commuters and the city traffic authorities.

However, current design process for customized bus service areasstill have some shortcomings. First, candidate routes can only besubmitted manually by users; second, changing routes frequently isinconvenient for both operators and riders. Therefore, a data-drivenapproach that extracts stable, salient commute patterns is needed.

Due to the ubiquity of GPS devices, large-scale taxi GPS datasetsare frequently used in mobility pattern mining, which can reliablyreflect the global repetitive commute demands[1]. In previous workof designing origination(O) and destination(D) service areas, [2]only considered hotness of pick-ups and drop-offs separately; [8]put OD relationship into consideration but broke it into segment-and-pair two-phase process, during which information can be lost.[7] used T-DBSCAN clustering method, which considered OD rela-tionships in one phase but has many design parameters to choose.

In this paper, we propose a newmethod of customized bus servicearea design. The main contributions are:

(1) We propose a new clustering method to embed high dimen-sional data into low dimensional feature for clustering, whichis a generalized method for high dimensional data clustering.

(2) We design a customized bus service area selection methodthat optimize both user convenience and resource cost.

2 ALGORITHMOurmethod is designed to satisfy the needs of both users and serviceoperators. Users want to minimize their walking distances to busstops; operators, on the other hand, want to maximize number ofpeople on the same bus so that people originate from the same areashould end around the same place.

Formally, we define the service area design problem as follows:Given the origins X and destinations Y of N taxi trips during a

given time-of-day, we want to find feature functions f : X → Rand д : Y → R, such that

(1) the intra-cluster weighted distance X and Y are minimized

minf ,д

12

∑i, j

e−(fi−fj )2 ∥Xi − X j ∥22 +

12

∑i, j

e−(дi−дj )2 ∥Yi − Yj ∥22 (1)

(2) the correlation between f (X ) and д(Y ) are maximizedmaxf ,д

E[f (X )]=E[д(Y )]=0,E[f 2(X )]=E[д2(Y )]=1

E[f (X )д(Y )] (2)

In objective (1), 2-D data X and Y are embedded into 1-D featuref (X ) and д(Y ) so that data close to each other in the original high-dimensional space should be close to each other in the feature space.The distance between the original data points Xi ,X j is weighted byfeature similaritiesw(fi , fj ), which should have two properties,

(1) w(fi , fj ) ∈ [0, 1],w(fi , fj ) = 1 means the distance betweenXi , X j is fully considered whilew(fi , fj ) = 0 means not.

(2) w(fi , fj ) is monotonically decreasing over ∆f = | fi − fj |, assimilarities between points decrease, the distance betweenthe original points should be considered less.

The exponential function is a good choice for weight w(·) whichsatisfies those two properties plus its advantage of fast convergencerate and simple derivative.

Objective (2) uses HGR maximal correlation[9], the only depen-dence measure that satisfies Rényi’s seven postulates, to quantizethe relationship between OD pairs.

This formulation (1), (2) have several benefits. First, correlationterm provides a tradeoff between walking distance and OD correla-tion. Second, f (·) and д(·) are real-valued and solving continuousoptimization problem is easier than integer ones. Third, f (·) andд(·) can be treated as 1-D embedded feature for further clusteringwithout the need to specify crucial parameters explicitly.

Note that this formulation has a trivial solution, where clusterscan be formed by individual points. We solve it by adding a dataweighted regularization term [6] to reduce number of clusters.

minf ,д

∑i, j

(e−∥Xi−X j ∥2 | fi − fj | + e−∥Yi−Yj ∥2 |дi − дj |) (3)

Combining (1), (2) and (3) with parameters γ for correlationtrade-off and λ for regularization trade-off. The final optimizationproblem is shown below. Although it is a non-convex optimizationproblem, it can be efficiently solved using projected gradient descentto converge.

minf ,д

E[f ]=E[д]=0E[f 2]=E[д2]=1

12

∑i, j

e−(fi−fj )2 ∥Xi −X j ∥22 +

12

∑i, j

e−(дi−дj )2 ∥Yi −Yj ∥22

−γ∑i

fi · дi + λ∑i, j

(e−∥Xi−X j ∥2e |fi−fj | + e−∥Yi−Yj ∥2e |дi−дj |)

Page 2: Extracting Commute Patterns for Customized Bus Service Area … · 2018-11-29 · SRC: ExtractingCommute Patterns for Customized Bus Service Area Design ... is a generalized method

Table 1: Clustering Similarity Index of Our Method Compared with 4d-kmeans and DBSCAN

Methods Adjusted Rand Index[4] Hubert Index[3] Adjusted Mutual Information[12]

4d-kmeans 0.58 ± 0.12 0.73 ± 0.10 0.59 ± 0.09DBSCAN[13] 0.76 ± 0.09 0.84 ± 0.09 0.70 ± 0.07

-2 0 2

f (origination)

0

20

40

Fre

quen

cy

-2 0 2g (destination)

0

20

40

Fre

quen

cy

x(km) -5 0 5

y(k

m)

-10

-8

-6

-4

-2

0

2

4

6

8

R1:o1-d1R2:o1-d2R3:o2-o1R4:o2-d2

(a) (b)Figure 1: Synthesized X-shapeData Result. (a) Histogram of 1-D em-bedded features f(origination) and g(destination) (b) Four identifiedX-shape routes

0 50 100 150 2006

2

3

4

5

6

Num

ber

of C

lust

ers Number of X clusters

Number of Y clusters

Figure 2: Effect of λ onNumber of O/DClusters on Synthesized Data

3 RESULTSSynthesized Data Result. Synthesized data {Xi ,Yi }200i=1 contains200 trips sampled from 4 unique routes from two origins (o1, o2)to two destinations (d1, d2) with added gaussian noise. Figure 1.ashows 4 peaks of embedded 1-D feature f (X ) and д(Y ) with γ = 1and λ = 130. Further clustering these features, we obtain result infigure 1.b, which perfectly recovers all 4 ground truth routes. Wealso validate the regularization effect of λ in Figure 2: number ofclusters decreases as λ increases. λ ∈ [60, 130] gives ground truthresult, which is the longest interval of λ.RealDataResult. NYCTaxi data[11] tripswith distance ∈ [7km, 10km]during 17:00-19:00, May 11th -May 22nd 2015 are considered. Set-ting parametersγ = 1 and λ = 30, our algorithm found 12 origin and15 destination service areas with 18 routes. In Figure 3, six majorcommute patterns are shown, which are from Brooklyn downtownto Brooklyn residential areas (Route3) or to Manhattan midtown(Route4), from upper Manhattan to lower Manhattan (Route2) orto Bronx (Route5), from Harlem District (Route6) and Long IslandCity (Route1) to LaGuardia Airport. Our result is consistent withthe typical commute patterns of New York City residents.Comparisons. We compare our method with classic clusteringmethods, 4D-kmeans and DBSCAN[13]. Similarities between ourmethod and baseline methods are computed using Adjusted RandIndex[4], Hubert’s Index[3] and Adjusted Mutual Information[12]under different parameter settings(k ∈ [2, 10] for kmeans, ϵd ∈[0.1, 0.2] and nmin ∈ [6, 16] for DBSCAN) shown as "mean±std"in Table 1. DBSCAN selects salient areas with large densities butlack good coverage while kmeans clusters all the points but havelower density. Our algorithm have similarities to both methods(allthe indexes are close to 1), which combines coverage and density.

Figure 3: NYC Data Result - 6 Major Routes (17:00-19:00, May 11th

to May 22nd , 2015)

4 CONCLUSIONSThis paper proposes a new method for CB service area design,which considers O/D connections and embeds original data into1-D feature space so that intrinsic nature of data can be obtainedfor further clustering. It also introduces the concept of maximalcorrelation to quantize the system performance, enabling the opera-tor to trade-off between user satisfaction and operation cost. In thefuture, we plan to design detailed bus routes within service areas.

ACKNOWLEDGMENTSThe author would like to thank Dr. Yang Li for discussions andadvisors Prof. Lin Zhang and Prof. Shao-lun Huang for guidance.

REFERENCES[1] Pablo Samuel Castro, Daqing Zhang, Chao Chen, Shijian Li, and Gang Pan.

2013. From taxi GPS traces to social and community dynamics: A survey. ACMComputing Surveys (CSUR) 46, 2 (2013), 17.

[2] Chao Chen, Daqing Zhang, Zhi-Hua Zhou, Nan Li, Tülin Atmaca, and ShijianLi. 2013. B-Planner: Night bus route planning using large-scale taxi GPS traces.In Pervasive Computing and Communications (PerCom), 2013 IEEE InternationalConference on. IEEE, 225–233.

[3] Lawrence Hubert. 1977. Nominal scale response agreement as a generalizedcorrelation. Brit. J. Math. Statist. Psych. 30, 1 (1977), 98–103.

[4] Lawrence Hubert and Phipps Arabie. 1985. Comparing partitions. Journal ofclassification 2, 1 (1985), 193–218.

[5] Ziru Li, Yili Hong, and Zhongju Zhang. 2016. An empirical analysis of on-demandride sharing and traffic congestion. (2016).

[6] Fredrik Lindsten, Henrik Ohlsson, and Lennart Ljung. 2011. Just relax andcome clustering!: A convexification of k-means clustering. Linköping UniversityElectronic Press.

[7] Yan Lyu, Chi-Yin Chow, Victor CS Lee, Yanhua Li, and Jia Zeng. 2016. T2CBS:Mining taxi trajectories for customized bus systems. InComputer CommunicationsWorkshops (INFOCOM WKSHPS), 2016 IEEE Conference on. IEEE, 441–446.

[8] Jihui Ma, Yang Yang, Wei Guan, Fei Wang, Tao Liu, Wenyuan Tu, and CuiyingSong. 2017. Large-Scale Demand Driven Design of a Customized Bus Network:A Methodological Framework and Beijing Case Study. Journal of AdvancedTransportation 2017 (2017).

[9] Alfréd Rényi. 1959. On measures of dependence. Acta mathematica hungarica10, 3-4 (1959), 441–451.

[10] David Schrank, Bill Eisele, Tim Lomax, and Jim Bak. 2015. 2015 urban mobilityscorecard. (2015).

[11] toddwschneider. 2017. Unified New York City Taxi and Uber data. https://github.com/toddwschneider/nyc-taxi-data/. (2017).

[12] Nguyen Xuan Vinh, Julien Epps, and James Bailey. 2010. Information theoreticmeasures for clusterings comparison: Variants, properties, normalization andcorrection for chance. Journal of Machine Learning Research 11, Oct (2010),2837–2854.

[13] Bing Zhu, Qixing Huang, Leonidas Guibas, and Lin Zhang. 2013. Urban popu-lation migration pattern mining based on taxi trajectories. In 3rd internationalworkshop on mobile sensing: the future, brought to you by big sensor data, Philadel-phia, USA.