Calibra on of the empirical fundamental rela onship using very large databases

Recebido: 29 de fevereiro de 2020 Aceito para publicação: 2 de dezembro de 2020 Publicado: 30 de abril de 2021 Editor de área: Sara Ferreira ABSTRACT This paper describes a procedure for fi/ng traffic stream models using very large traffic databases. The proposed approach consists of four steps: (1) an ini.al treatment to eliminate noisy, inaccurate data and to homogenize the informa.on over the density range; (2) a first fi/ng of the model, based on the sum of squared orthogonal errors; (3) a second filter, to eliminate outliers that survived the ini.al data treatment; and (4) a second fi/ng of the model. The proposed approach was tested by fi/ng the Van Aerde traffic stream model to 104 thousand observa.ons collected by a permanent traffic monitoring sta.on on a freeway in the metropolitan region of São Paulo, Brazil. The model fi/ng used a gene.c algorithm to search for the best values of the model parameters. The results demonstrate the effec.veness of the proposed approach.


INTRODUCTION
Traf ic stream analysis usually uses data collected by traf ic sensors at permanent traf ic monitoring stations (PTMS), which, working continuously over months and years, can accumulate a very large amount of observations. However, this data includes noise that can skew the models. Road construction, accidents, bad weather, sensor malfunction, and incidents that affect the traf ic stream behavior are unusual conditions that do not represent regular road operation.
It can be expected that in a very large database (VLDB) covering several years, a considerable portion of the speed-low observations includes noise.
This study proposes a process for itting traf ic stream models using very large data sets. The proposed method includes a irst treatment to standardize the volume of information across the range of traf ic stream densities and reduce noise. The model is then calibrated by a two-step optimization process to eliminate the noise that survived the irst ilter. The proposed procedure used a genetic algorithm (GA) to search for the best values for model parameters, but any other optimization technique could be used. The traf ic stream model chosen to test the process was the one proposed by Van Aerde (Rakha, 2009), as it is a well-known model; any other model, however, could have been used.

LITERATURE REVIEW 2.1. Traffic stream models and their calibra on
A traf ic stream model describes the macroscopic relationships between low ( ), speed ( ) and density ( ) (May, 1990) in a system of equations consisting of: (3) where Eq.1 is a continuity equation concerning the space ( ) and time ( ) domain; Eq. 2 is a state equation, and Eq.3 establishes a relation (function ) between speed and density (Lu et al., 2010). The fundamental hypothesis for de ining a model is that, for each speci ic location, there is a relationship among , , and , called the fundamental equation (Eq. 2), which contains the solutions for a steady-state model for this traf ic stream (Kerner, 2004). Traf ic stream models are the subject of constant studies given their informational capacity regarding the characteristics of the roads and drivers (Coifman, 2014).
The empirical fundamental relationship (the speed-density or speed-low models) is itted using data collected by traf ic monitoring stations (Hall et al., 1992;Coifman, 2014), which provide, for a given observation time interval, measurements of low rate, speed, and occupancy (of which density can be estimated), to which one an error is associated. It is well known that the regression of a dependent variable as a function of an independent variable such that = ( ) does not produce the same relation as the regression of as a function of (Draper & Smith, 1980). To avoid this problem, in a regression, one must clearly de ine which independent variables and which dependent variables, since it assumes that only the dependent variable contains a measurement error. When itting a traf ic model, this means that the regression = ( ), which presupposes that the density is the explanatory (independent) variable and that the speed is the dependent variable, minimizes only the error associated with the estimated speed. Rakha & Arafeh (2010) demonstrate that this is not the case with traf ic stream models since it is not easy to de ine which the independent variable is and that, depending on the situation, any of the three variables may be the determining factor for traf ic behavior, and all three variables inherently carry a measurement error.
To overcome this problem, Rakha & Arafeh (2010) suggested that the calibration should be based on a neutral regression, which does not require the determination of the dependent variable, and the adjustment seeks to minimize the normalized orthogonal quadratic error of the fundamental diagram of the chosen model. This optimization model can be described as: subject to: where is the estimated orthogonal quadratic error; $ , $ and $ observed speed, low, and density values for the &-th observation; $ , $ and ! $ are the estimated values for speed, low, and density for a &-th observation; and , and " are the maximum observed values for speed, low, and density. The neutral regression method can be applied to any traf ic stream model (Rakha & Arafeh, 2010) and can be solved using any optimization technique.
This formalism supports the development of empirical low-density and speed-density relationships, based on empirical observations of the values of u and q (Kerner, 2004). Permanent traf ic monitoring stations, where sensors count and classify vehicles and measure their speed, are used to collect traf ic stream data. Because each road segment has its own peculiarities, these empirical observations of traf ic variables lead to a unique fundamental diagram (Knoop & Daamen, 2017). The collection of empirical data, however, is associated with some problems that need attention before the data is ready for model itting.

Empirical data for fi'ng traffic stream models
The use of raw traf ic data to calibrate empirical fundamental relationship is linked to many problems (Knoop & Daamen, 2017): (i) the traf ic stream may not be in equilibrium during the observation period; (ii) the traf ic stream is heterogeneous; (iii) the detectors have limitations (such as not being able to detect stationary vehicles) and are subject both to failure and measurement errors; (iv) the number of vehicles measured during an interval is always integer; and (v) the average speed recorded by the sensor is the time-mean speed. Regarding this last aspect, Knoop et al. (2009) compared the time-mean speed and the space-mean speed using individual vehicle data for a motorway segment, showing that "the space-mean speed gives a better it for the fundamental diagram". The authors also point out that the use of time mean speeds affect mostly the congested low region, underestimating the jam density and the shockwave speed.
Fitting traf ic models to empirical data bring up another problem, which is the noise inherent to the traf ic sensor data. There may be incidents (e.g., roadwork, traf ic bans, accidents, bad weather, sensor malfunctions, etc.) during the period over which the data is collected that are not representative of the normal operation. This noise (i.e., inaccurate information) can negatively affect the quality of the itted model. In the absence of reliable information about such incidents, it is necessary to create a way to ilter the raw data to minimize the noise. Models used to detect freeway incidents, which incorporate techniques such as fuzzy logic, wavelets, and neural networks to reduce noise and increase their reliability (Karim & Adeli, 2002) demonstrate the importance of raw data iltering.

The use of large databases for the calibra on of traffic models
With the increasing availability of data collected by PTMS, the use of large databases for the calibration of traf ic models became more common. The literature shows traf ic models calibrated using data collected during peak hours on speci ic days (Ma & Abdulhai, 2002 , 2003;Yang & Ozbay, 2011;Balakrishna et al., 2007;Henclewood et al., 2013) and covering several days or weeks Toledo et al., 2004;Qin et al., 2004;Lee & Ozbay, 2009;Zhang et al., 2008;Knoop et al., 2009). When traf ic data covers several months and even years, the database comprises tens of thousands of observations and is considered a very large database (VLDB). Dealing with VLDB, Dervisoglu et al. (2009) reported using 27,000 observations obtained good results in fundamental diagram calibration observing the breakdown point. Qu et al. (2015) used 48,000 observations and a weighted least square method to calibrate both light-traf ic/free-low conditions and congested/jam conditions separately; and Zhong et al. (2016) have used 10,000 observations for a cell transmission model itting which implied the division of the data in analysis regions (cells) and training sets. Using a VLDB to it a traf ic model requires automating the calibration procedure, due to the sheer amount of data processed. The following sections in this paper describe the traf ic data and the proposed approach.

THE PROPOSED APPROACH
To calibrate the fundamental diagram using a very large database (VLDB), the proposed approach consists of the following steps: (1) data aggregation; (2) noise reduction; (3) irststage model calibration; and (4) second-stage model calibration. All steps are based on average speed ( ) and density ( ) data, because there is a monotonous relationship between these two variables (Wu, 2002): never increases with an increase in -i.e., low densities imply in high average speeds and vice-versa. The next sections explain the proposed approach.

Data aggrega on
A very large traf ic database includes observations on congested and non-congested low regimes, with the former being much rarer than the latter, even for locations where traf ic jams are very common. Thus, a scatterplot of ( , ) data will show many more data points representing uncongested lows than congested lows. This unbalance will bias the model, resulting in a poorly it model, whichever calibration procedure is used. The best way to eliminate this bias is to aggregate the data into density classes, in such way that all classes have the same weight in the calculations to it the model (Wu, 2002;Rakha & Arafeh, 2010).
Instead of providing individual vehicle data (speed, class and timestamp), from which spacemean speed and density could be easily derived, typical PTMS data consist of vehicle counts and average speeds for predetermined time intervals (5 or 15 minutes). From such data, density for a given observation interval may be estimated using = /,, assuming that the time-mean speed , is an adequate estimate of the space-mean speed. With the ( , ) data, the next step is choosing the range of the density classes. The selected range must provide a suf iciently large number of data points for itting the model and the choice will depend on the available data and other intervening factors.
Within each class, several individual observations of speed and density will be available. However, a single pair of values ( , ) should be obtained for each density class. Coifman (2014) chose the average speed median and the density median. In this study, the selection of the value for speed and density employed the cumulative distribution, using a prede ined percentile, similar to the approach used by Punzo & Montanino (2016) The next step in the method is noise attenuation.

Noise reduc on
In a traf ic stream, high speeds are associated with low density values. Thus, observations made at very low densities should theoretically result in average speeds close to the free low speed. In a VLDB, it is possible to ind very low densities linked to very low speeds, representing anomalous operating conditions (road maintenance, lane closures, bad weather, etc.). Ideally, information on periods of anomalous operating conditions would be available to purge this noise from the database.
In many cases, however, such information is not readily available or is not dependable. For these situations, a noise attenuation step improves the quality of the itted model. A preliminary dataset analysis indicated that the initial data aggregation procedure eliminates some, but not all, of this noise. Evidence of anomalous data is the presence of data points with low densities and low speeds after the irst step. In this study, investigations on possible ways to reduce the noise in low-density data points indicated that eliminating very low-density data points from the dataset would affect the itted model minimally. The proposed approach employs a ilter that requires the selection of -./ , a lower threshold value for density -that is, any data point with $ ≤ -./ is purged from the dataset. The value of this density threshold is highly dependent on the dataset. A good indication of this threshold is the density beyond which speed never increases with an increase in density.
The model calibration in two stages also helps to reduce noisy data associated with highdensity observations, as explained in the next sections.

First-stage model calibra on
Once most of the noise is purged from the data, the irst stage of the model calibration ensues. The user must choose the traf ic stream model and the optimization method that will be used in this step. For instance, Wang et al. (2011) and Ni (2016) review several traf ic models that could be used for this purpose.
Any optimization method may be used to calibrate the model with a carefully chosen objective function. At the end of this stage, a itted model = 1 ( ) is available to support the secondstage calibration.
Some researchers (Rakha & Arafeh, 2010;Wang et al., 2011) used a single calibration stage and obtained very good models; none of them, however, employed a VLDB to it the model. The absence of reliable information on the occurrence of anomalous operating conditions to purge the VLDB, however, might imply in some loss of accuracy due to noise escaping the ilters of the irst two steps in the method. Hence, a second-stage calibration is included to further re ine the itted model.

Second-stage model calibra on
The second-stage calibration uses the irst-stage model = 1 ( ) to remove outlying data points missed by the initial ilter. To do so, for each density class &, an estimate of the average speed $ = 1 ( $ ) is calculated and compared to the average speed $ for that class. If | $ − $ | ≥ 4, where 4 is a predetermined acceptable tolerance, that data point is considered as an outlier and discarded. The value of 4 should be selected carefully, after inspection of the data and the itted model. The dataset obtained after this last ilter is then used to it the model through the same optimization method used in the irst-stage calibration. The proposed approach can be easily automated using any programming language. The next sections explain how this was done in this study.

CASE STUDY
To demonstrate the effectiveness of the proposed approach, it was applied to the calibration of the fundamental diagram of a segment of freeway in the metropolitan region of São Paulo, Brazil, using a database comprising more than 104,000 observations.

Descrip on of traffic data
The permanent traf ic monitoring station (PTMS) selected to test the proposed approach is installed on a freeway section without signi icant longitudinal grades, where access is controlled and is outside the area of in luence of on-or off-ramps. In addition, because capacity is routinely reached at this location, the data contains observations in the uncongested and the congested low regions. This PTMS is located on a major freeway in the metropolitan region of São Paulo (SP070, km 39.5 East), on a three-lane segment that can be considered a basic freeway section. The closest off-ramp is located at approximately 4 km downstream from the PTMS; the nearest on-ramp is located around 3 km upstream from the sensor. Traf ic data were provided by ARTESP (São Paulo State Transportation Agency) and cover the period from September 1, 2011 to December 31, 2017.
The PTMS chosen collects traf ic data using inductive loop sensors. Data records consist of date, time, heavy vehicle count, passenger car count, and average speed for 15-minutes intervals. The average speed is the time-mean speed for the 15-minute interval and not the spacemean speed, as would be desirable. For this study, only the observations recorded between 5 AM and 10 PM were used, as it was considered that the traf ic at late hours and dawn is not representative, due to the low volume of passenger-cars and the large percentage of heavy vehicles. In this section of the freeway, the speed limit for passenger cars (120 km/h) is higher than the speed limit of heavy vehicles (90 km/h). The average speed recorded by the PTMS is the average speed of all vehicles (cars and heavy vehicles) traveling over the segment.
As described in another paper (Cardoso et al. 2019), the data were treated to eliminate observations made in rainy weather, based on information from weather radar from IPMet/UNESP. In addition to this treatment, in processing data for VLDB composition, observations that showed apparent errors of sensor malfunctioning were excluded (such as the presence of repeated values several times, hugely discrepant values regarding the time series, absence of information and so on). After this step, the database contained 103,606 observations. However, these data contain noise, because there was no information on roadwork, accidents, sensor malfunction, and other incidents that may interfere with the regular operation of the traf ic.

Data aggrega on
To be successful, the calibration of a traf ic model requires information on uncongested and congested conditions. Even in a freeway that regularly experiences traf ic jams (such as the one chosen for this study), it is far more common to ind uncongested 15-minute periods than it is to ind congested 15-minute periods in one year. Therefore, there will be an imbalance in information on congested and uncongested conditions, biasing the itted model. Figure 1 illustrates the problem of using raw data for model itting. In the plot, the darker the color of a data point, the greater the frequency of the values represented by that data point, as the gray scale on the graph legends shows. The number of observations made under congested conditions (high density, low speed and low low rates) is much smaller than the number of observations made under uncongested conditions. Furthermore, there is a great concentration of observations between 5 and 10 pce/km/lane, with speeds around 110 km/h and low rates between 400 and 1200 pce/h/lane. The blue lines represent a model itted to the 103,606 data points. The resulting 900 pce/h/lane capacity is much lower than the observed maximum low rates, indicating the bias caused by the large number of observations in the darker gray area in Figure 1, as they will have a higher weight in the estimation of the itted model error. The best way to reduce this undesirable effect consists of aggregating the raw data so that all density ranges have the same weight in model calibration (Rakha & Arafeh, 2010).
For the data aggregation, low rates were converted from veh/h/lane into pce/h/lane using the PCE value adopted by ARTESP ( 5 = 2.5) and densities were estimated using Equation 2, where is the low rate, in pce/h/lane, and is the average speed of all vehicles (in km/h) and the density is given in pce/km/lane. The class range selected for this study is 0.25 pce/km/lane, because it provided a suf iciently large number of data points for itting the model. For each class, the mean, median and 85thpercentile of speed and density were calculated, as shown in the histogram in Figure 2. The values for speed and density for each class were the 85th-percentiles of the cumulative speed and density distributions for the class (as shown in Figure 2). The 85th percentile was chosen on the assumption that it better represents the average speed of cars, given that the raw data is the average speed of all vehicles (cars and heavy vehicles) and that, in this segment of the freeway, the posted speed limit for cars is 30 km/h higher than the speed limit for heavy vehicles. The aggregation of data transformed the 103,606 observations into 146 pairs of speed and density data, ensuring that the information about the behavior of the traf ic stream is homogeneously distributed over the range of observed densities. Figure 2 shows the raw data, the mean and the median for each density class. It is possible to notice that, despite covering more than TRANSPORTES | ISSN: 2237-1346 220 6 years, the ield data contains little information about the region close to the jam density ( > 40 veic/km/lane). This is a limitation of the data set; if the data had been collected at shorter intervals (for instance, at 5-minute intervals instead of 15-minute intervals), perhaps higher densities would have appeared more frequently in the traf ic data. Figure 1 also shows the effect of noise in the raw ield data, which is more apparent on the speed-density graph. The region where density is low ( < 5 pce/km/lane) and speed is also low ( < 80 km/h) represent highly anomalous operating conditions, in which vehicles are traveling at speeds far below the posted speed limit (120 km/h) with inter-vehicular spacing greater than 200 m, when one would expect that such spacing should correspond to speeds close to the free speed. Figure 2 shows that the data aggregation eliminates some of the noise, but some noise still remains in the low-density region. For a traf ic stream behaving normally, the speed-density relationship is a monotonically decreasing function -that is, the speed decreases or stays constant with the increase of density. When the raw data contains anomalous operating conditions (such as, when < 5 veic/km/lane, in Figure 2), this condition does not exist. To reduce the noise associated with the identi ied low-density anomalous observations, only data points with density greater than low should be used in the calibration. For this site, low was selected as 5 pce/km/lane and the application of this ilter reduced to number of data points to 126 from 146.

Selec on of the traffic model
The proposed approach can use any traf ic model. For this case study, the model selected was the Van Aerde model (Van Aerde, 1995), because it is a versatile model that can model both uncongested and congested lows with the same equation. The Van Aerde model combines the Pipes and Greenberg models (Lu et al., 2010) and can represent free and congested lows through a single mathematical function, without the need to establish breakpoints that separate these two regimes (Van Aerde, 1995;Rakha, 2009). Due to its mathematical structure, this model can adequately represent the behavior of traf ic low on freeways, two-lane roads, or even urban arterial roads (Rakha & Crowther, 2003) and, because of this versatility, the German capacity manual HBS (Handbuch für die Bemessung von Straßenverkehrsanlagen) has adopted the Van Aerde model (FGSV, 2015).
The Van Aerde traf ic stream model is based on four parameters: the free low speed = , the speed at capacity > , the low rate at capacity > , and the jam density ? (Rakha, 2009). Mathematically, the model is expressed by: where H 1 , H , and H I are constants that can be calculated using the following equations (Demarchi, 2003):

Selec on of the op miza on technique for model calibra on
Van Aerde & Rakha (1995) used a hill-climbing search to it the traf ic model to the data; Rakha & Arafeh (2010) adopted a multistage search to ind the set of parameters that best it the data. In this study, a genetic algorithm (GA) was used to it the Van Aerde traf ic model to the data, because genetic algorithms are able to better explore the solution space from a multitude of points and, therefore, are less susceptible to entrapment by local minima. Genetic algorithms are a stochastic search method that mimics the theory of evolution and natural selection, in the sense that individuals best adapted to the environment (the better solutions to the problem) are more likely to survive. In GAs, a itness function measures the degree of adaptation to the environment of an individual -i.e., the quality of a given solution (Goldberg 1989, p. 9).
The itness function adopted for the GA is given by Eq. 13. By normalizing the low, density, and speed values, the optimization problem can be expressed by: subject to speci ic restrictions for this application, which are: > ∈ S1000, 3000U pce/h/lane, and where lim is the posted speed limit, and all the other variables have already been de ined. The lowchart of Figure 3 shows the structure of the genetic algorithm, which was coded in Python v.3.7.0. The process starts with the creation of a population of X individuals. Due to the particularities of each problem, there is no general rule for de ining the population size X (Diaz- Gomez & Hougen, 2007). The size X of the initial population is a critical factor as it has a major in luence on the computational cost of the process. If X is too small, the algorithm might converge early, while a too large X might waste computational resources due to the high number of iterations required to improve the result (Arabas et al., 1994). The classic approach that de ines X by the rule X = 10 × Y, with Y being the number of genes (Storn, 1996), was chosen. As, for this study, Y = 4, then X = 40.
Each individual or solution consists of a randomly created set of four model parameters (genes): free-low speed ( = ), speed at capacity ( > ), low rate at capacity ( > ), and jam density ( ? ). In the generation of individuals, a series of checks ensures that the solution is feasible. Eqs.17 to 24 express these restrictions.
Once the initial population is established, the ittest individual must be found. To do this, the following steps are taken for all solutions in the population: 1) H 1 , H and H I are calculated from = , > , > , and ? using Eqs. 10 to 12; 2) Eq.14 and H 1 , H and H I are used to calculate ! $ ; 3) $ is computed using Eq.15; 4) $ is found using Eq.16; and 5) The individual's itness, the orthogonal quadratic error $ is calculated using Eq. 13. Once the process has been completed for the population, the individuals are ranked according to their itness $ , with the lowest value of ranking irst in the list.
The evolution of this population (i.e., the search for the best solution) happens through the application of genetic operators (elitism, selection, crossover, mutation and predation) in combination with each individual's itness.
Predation culls less adapted individuals (the worst solutions), replaced by randomly created new individuals (Srinivas & Patnaik, 1994). With each generation, there is a ixed chance for predation to occur. In this study, predation eliminates the worst individuals at a rate of Z = 10%, with a probability of \ Z = 30% occurring with each iteration (Sivanandam & Deepa, 2007).
Elitism, selection and crossover are the operators used to create the new generation. Elitism places the best-itted individual of one generation into the next, ensuring that a good solution will not be lost by chance during the selection of individuals to generate offspring. The (X − 1) other individuals of the new generation are created from two parents chosen by the roulette wheel method (Chambers, 2000), based on the itness of the parents: better-adapted individuals have a greater number of offspring in the next generation. To do so, the sum ] of all errors $ is calculated and the probability ^$ of choosing an individual is inversely proportional to its contribution to ]. After both parents are selected by this method, a random draw, with equal probability of occurrence, is conducted to determine if one, two, three, or four genes will come from one parent, with the complementary genes coming from the other parent. This combination of genes (crossover) creates a new individual for the next generation. The process is repeated until the individuals necessary to complete the future generation population have been created. From time to time, the mutation operator is used to increase population variability. Mutation is applied at a constant rate _ = 10% of the population with a random probability of occurrence \ _ = 20% per generation. Mutation makes it possible to escape scenarios of little variability in the population, where descendants tend to be exact replicas of parents. In such cases, mutation is an opportunity to generate a new and better individual from a stagnating population (Coley, 1999).
The process of evolution continues through the generations until the maximum number of generations is reached, or the itness value stabilizes. The individual best adapted to the environment of this generation represents the best solution.
For this study, the number of generations used is 1000, to explore as many solutions as possible. This number of iterations, perhaps exaggerated, was selected due to the low computational cost to reach this level, about 10 minutes, and also because more generations did not result in better solutions in the tests performed.
The parameters of a GA are usually chosen on a pragmatic way, seeking to maintain diversity at a gene-level, a population-level, or even a combination of both, to obtain good-quality solutions avoiding premature convergence, as well as considering the computational costs of each alternative (Diaz-Gomez & Hougen, 2007). The values chosen for this GA are very common in optimization problems and were tried in test runs. Anyhow, Reeves (1993) points out that a properly selected itness function is far more important to ensure that an optimization state is reachable from any starting point within the search space than the chosen values for the GA parameters.

First-stage model calibra on
The GA was then used to search for the best values for the Van Aerde model parameters, for the traf ic data. Figure 4 shows the calibrated model (black line) over the raw data. The colored points on the graph show the data used for model calibration. The values found for the parameters of the Van Aerde model at the end of this initial stage were: (i) free-low speed = = 110 km/h; (ii) speed at capacity > = 89 km/h; (iii) low rate at capacity > = 1761 pce/h/lane; and (iv) jam density ? = 65 pce/km/lane.

Second-stage model calibra on
To re ine the model obtained after the previous step, a second stage, consisting of a new ilter followed by a further model itting, was employed. This ilter, mathematically expressed as | $ ( $ ) − $ ( $ )| ≥ 4 km/h, was applied to the 126 data points shown in Figure 4, eliminating those for which the absolute difference between the estimated speed and the observed speed for the correspondent density was higher than tolerance 4. For this application, a tolerance 4 = ±10 km/h was used. This second ilter eliminated 17 observations from the set of 126 observations initially used (marked in red in Figure 4).
The value of tolerance 4 was chosen in a pragmatic way, similarly to that used for the selection of the GA parameters. Several values were tested, trying to balance the need for the elimination of residual noise and the need for preserving the greatest amount of information for model calibration. The value adopted for 4, 10 km/h, was assumed to be a good compromise between these two con licting objectives.   Figure 5, the blue lines describe the model itted to the raw PTMS data, whereas the red lines are the results of the proposed approach.
Little difference can be observed between the models itted in the irst stage and second stage calibration. This is due to two aspects, the irst of which is the lack of information on traf ic lows with speed lower than 25 km/h and density greater than 40 pce/km/lane, which in luences the estimation of jam density. The GA search is more effective when more information (observed values) is available because this has a greater effect on the itness value of a solution. The second aspect is that this result shows that steps 1 (data aggregation) and 2 (noise ilter) in the proposed approach are quite ef icient in removing the data noise, at least for the particular data set.

DISCUSSION OF RESULTS
To evaluate the proposed approach, the GA stopping criterion was a very large number of generations (1000) and the calibrated model goodness of it of was evaluated by a b metric de ined as: where $ is the orthogonal square error of the best solution of the &-th generation, de ined by Equation 13; and α, β and γ are scale factors whose values were arbitrarily chosen to be α = 100, β = 5 and γ = 1. Equation 25 shows that 0 < b $ ≤ 100; that is, the larger the orthogonal quadratic error $ , the lower the value of b $ and if $ = 0 ⇒ b $ → 100. b is a measure of the goodness of it of the model as the genetic algorithm evolves. Figure 6 shows the evolution of b as the number of solutions tested by the GA increases with each new generation. Note that each generation involves testing at least 39 solutions -more if predation and mutation operators are applied in that generation. Fitting the Van Aerde model to the raw PTMS data results in a maximum itting quality of 14.2 after testing approximately 27360 solutions. The low quality of it is explained by the great number of observations under low low rates, which justi ies the need to apply the proposed approach to homogenize the information over the full range of observed densities.
Using the proposed approach, which its the model to iltered data, results in b = 91.7 after the irst-stage calibration, with just 5480 solutions tested. The second-stage calibration results in a small increase in the model's goodness-of-it: b = 93.1 after 26400 solutions tested. The small increment in the goodness of it obtained in the inal stage indicates that the proposed approach eliminates most of the noise, at least for this particular data set. In that way, one can consider the second stage representing a ine tune of the calibration process. If there are available computational resources and the desire to obtain a detailed solution, it is recommended to carry out the second stage. In the case of a lack of computational resources, the method can be interrupted after the execution of the irst stage, without signi icant losses.
Because this GA starts with an initial population of 40 randomly created individuals, it is much more likely that fairly good solutions would appear within the initial generations, as was the case in this study, as the values of b for the irst generation were 65.01, in the irst stage, and 81.85, in the second stage. However, this fact does not guarantee that same inal results will be veri ied at the same number of tested solutions, but only suggests that the proposed approach can converge quickly to a good result thanks to the stochastic nature of the population created at the start of the algorithm.

FINAL CONSIDERATIONS
This paper has demonstrated that direct use of traf ic data from a VLDB does not result into a properly calibrated traf ic stream model, if the VLDB, like the one used in this study, includes a large number of repeated observations and noise. To solve these problems, the proposed approach reduces raw data into narrow density bins so that information is equally distributed over the range of observed densities in such way that all bins had equal weight on the itted model and noise was minimized.
The implementation of a genetic algorithm allowed for an ef icient way of searching for the search of the best solution because a GA is more likely to initiate the iterative search process from a superior solution and can better exploit the feasible set that satis ies the problem constraints. The proposed approach can be easily adapted to other traf ic stream models and/or search mechanisms.