Check out the latest version of Routino: svn co http://routino.org/svn/trunk routino
Contents of /trunk/doc/USAGE.txt
Parent Directory
|
Revision Log
Revision 1396 -
(show annotations)
(download)
Thu Jun 13 18:08:26 2013 UTC (11 years, 9 months ago) by amb
File MIME type: text/plain
File size: 25430 byte(s)
Thu Jun 13 18:08:26 2013 UTC (11 years, 9 months ago) by amb
File MIME type: text/plain
File size: 25430 byte(s)
Document that --errorlog and --keep together will create the binary database of errors.
1 | Routino : Usage |
2 | =============== |
3 | |
4 | |
5 | There are five programs that make up this software. The first one takes |
6 | the planet.osm datafile from OpenStreetMap (or other source of data |
7 | using the same formats) and converts it into a local database. The |
8 | second program uses the database to determine an optimum route between |
9 | two points. The third program allows visualisation of the data and |
10 | statistics to be extracted. The fourth program allows dumping the raw |
11 | parsed data for test purposes and the fifth is a test program for the |
12 | tag transformations. |
13 | |
14 | planetsplitter |
15 | -------------- |
16 | |
17 | This program reads in the OSM format XML file and splits it up to |
18 | create the database that is used for routing. |
19 | |
20 | Usage: planetsplitter [--help] |
21 | [--dir=<dirname>] [--prefix=<name>] |
22 | [--sort-ram-size=<size>] [--sort-threads=<number>] |
23 | [--tmpdir=<dirname>] |
24 | [--tagging=<filename>] |
25 | [--loggable] [--logtime] |
26 | [--errorlog[=<name>]] |
27 | [--parse-only | --process-only] |
28 | [--append] [--keep] [--changes] |
29 | [--max-iterations=<number>] |
30 | [--prune-none] |
31 | [--prune-isolated=<len>] |
32 | [--prune-short=<len>] |
33 | [--prune-straight=<len>] |
34 | [<filename.osm> ... | <filename.osc> ... |
35 | | <filename.pbf> ... |
36 | | <filename.o5m> ... | <filename.o5c> ... |
37 | | <filename.(osm|osc|o5m|o5c).bz2> ... |
38 | | <filename.(osm|osc|o5m|o5c).gz> ...] |
39 | |
40 | --help |
41 | Prints out the help information. |
42 | |
43 | --dir=<dirname> |
44 | Sets the directory name in which to save the results. Defaults |
45 | to the current directory. |
46 | |
47 | --prefix=<name> |
48 | Sets the filename prefix for the files that are created. |
49 | Defaults to no prefix. |
50 | |
51 | --sort-ram-size=<size> |
52 | Specifies the amount of RAM (in MB) to use for sorting the data. |
53 | If not specified then 64 MB will be used in slim mode or 256 MB |
54 | otherwise. |
55 | |
56 | --sort-threads=<number> |
57 | The number of threads to use for data sorting (the sorting |
58 | memory is shared between the threads - too many threads and not |
59 | enough memory will reduce the performance). |
60 | |
61 | --tmpdir=<dirname> |
62 | Specifies the name of the directory to store the temporary disk |
63 | files. If not specified then it defaults to either the value of |
64 | the --dir option or the current directory. |
65 | |
66 | --tagging=<filename> |
67 | Sets the filename containing the list of tagging rules in XML |
68 | format for the parsing the input files. If the file doesn't |
69 | exist then dirname, prefix and "profiles.xml" will be combined |
70 | and used, if that doesn't exist then the file |
71 | '/usr/local/share/routino/profiles.xml' (or custom installation |
72 | location) will be used. |
73 | |
74 | --loggable |
75 | Print progress messages that are suitable for logging to a file; |
76 | normally an incrementing counter is printed which is more |
77 | suitable for real-time display than logging. |
78 | |
79 | --logtime |
80 | Print the elapsed time for each processing step. |
81 | |
82 | --errorlog[=<name>] |
83 | Log OSM parsing and processing errors to 'error.log' or the |
84 | specified file name (the '--dir' and '--prefix' options are |
85 | applied). If the --append option is used then the existing log |
86 | file will be appended, otherwise a new one will be created. If |
87 | the --keep option is also used a geographically searchable |
88 | database of error logs is created for use in the visualiser. |
89 | |
90 | --parse-only |
91 | Parse the input files and store the data in intermediate files |
92 | but don't process the data into a routing database. This option |
93 | must be used with the --append option for all except the first |
94 | file. |
95 | |
96 | --process-only |
97 | Don't read in any files but process the existing intermediate |
98 | files created by using the --parse-only option. |
99 | |
100 | --append |
101 | Parse the input file and append the result to the existing |
102 | intermediate files; the appended file can be either an OSM file |
103 | or an OSC change file. |
104 | |
105 | --keep |
106 | Store a set of intermediate files after parsing the OSM files, |
107 | sorting and removing duplicates; this allows appending an OSC |
108 | file and re-processing later. |
109 | |
110 | --changes |
111 | This option indicates that the data being processed contains one |
112 | or more OSC (OSM changes) files, they must be applied in time |
113 | sequence if more than one is used. This option implies --append |
114 | when parsing data files and --keep when processing data. |
115 | |
116 | --max-iterations=<number> |
117 | The maximum number of iterations to use when generating |
118 | super-nodes and super-segments. Defaults to 5 which is normally |
119 | enough. |
120 | |
121 | --prune-none |
122 | Disable the prune options below, they can be re-enabled by |
123 | adding them to the command line after this option. |
124 | |
125 | --prune-isolated=<length> |
126 | Remove the access permissions for a transport type from small |
127 | disconnected groups of segments and remove the segments if they |
128 | end up with no access permission (defaults to removing groups |
129 | under 500m). |
130 | |
131 | --prune-short=<length> |
132 | Remove short segments (defaults to removing segments up to a |
133 | maximum length of 5m). |
134 | |
135 | --prune-straight=<length> |
136 | Remove nodes in almost straight highways (defaults to removing |
137 | nodes up to 3m offset from a straight line). |
138 | |
139 | <filename.osm>, <filename.osc>, <filename.pbf>, <filename.o5m>, |
140 | <filename.o5c> |
141 | Specifies the filename(s) to read data from. Filenames ending |
142 | '.pbf' will be read as PBF, filenames ending in '.o5m' or '.o5c' |
143 | will be read as O5M/O5C, otherwise as XML. Filenames ending |
144 | '.bz2' will be bzip2 uncompressed (if bzip2 support compiled |
145 | in). Filenames ending '.gz' will be gzip uncompressed (if gzip |
146 | support compiled in). |
147 | |
148 | Note: In version 2.5 of Routino the ability to read data from the |
149 | standard input has been removed. This is because there is now the |
150 | ability to read compressed files (bzip2 and gzip) and PBF files |
151 | directly. Also using standard input the file type cannot be |
152 | auto-detected from the filename. |
153 | |
154 | Example usage 1: |
155 | |
156 | planetsplitter --dir=data --prefix=gb great_britain.osm |
157 | |
158 | This will generate the output files 'data/gb-nodes.mem', |
159 | 'data/gb-segments.mem' and 'data/gb-ways.mem'. Multiple filenames can |
160 | be specified on the command line and they will all be read in, combined |
161 | and processed together. |
162 | |
163 | Example usage 2: |
164 | |
165 | planetsplitter --dir=data --prefix=gb --parse-only great_britain_part1.osm |
166 | planetsplitter --dir=data --prefix=gb --parse-only --append great_britain_part2.osm |
167 | planetsplitter --dir=data --prefix=gb --parse-only --append ... |
168 | planetsplitter --dir=data --prefix=gb --process-only |
169 | |
170 | This will generate the same output files as the first example but |
171 | parsing the input files is performed separately from the data |
172 | processing. The first file read in must not use the --append option but |
173 | the later ones must. |
174 | |
175 | Example usage 3: |
176 | |
177 | planetsplitter --dir=data --prefix=gb --keep great_britain.osm |
178 | |
179 | planetsplitter --dir=data --prefix=gb --changes great_britain.osc |
180 | |
181 | This will generate the same output files as the first example. The |
182 | first command will process the complete file and keep some intermediate |
183 | data for later. The second command will apply a set of changes to the |
184 | stored intermediate data and keep the updated intermediate files for |
185 | repeating this step later with more change data. |
186 | |
187 | The parsing and processing can be split into multiple commands as it |
188 | was in example 2 with the --keep option used with --process-only for |
189 | the initial OSM file(s) and the --changes option used with --parse-only |
190 | or --process-only for every OSC file. |
191 | |
192 | router |
193 | ------ |
194 | |
195 | This program performs the calculation of the optimum routes using the |
196 | database generated by the planetsplitter program. |
197 | |
198 | Usage: router [--help | --help-profile | --help-profile-xml | |
199 | --help-profile-json | --help-profile-perl ] |
200 | [--dir=<dirname>] [--prefix=<name>] |
201 | [--profiles=<filename>] [--translations=<filename>] |
202 | [--exact-nodes-only] |
203 | [--loggable | --quiet] |
204 | [--output-html] |
205 | [--output-gpx-track] [--output-gpx-route] |
206 | [--output-text] [--output-text-all] |
207 | [--output-none] |
208 | [--profile=<name>] |
209 | [--transport=<transport>] |
210 | [--shortest | --quickest] |
211 | --lon1=<longitude> --lat1=<latitude> |
212 | --lon2=<longitude> --lon2=<latitude> |
213 | [ ... --lon99=<longitude> --lon99=<latitude>] |
214 | [--heading=<bearing>] |
215 | [--highway-<highway>=<preference> ...] |
216 | [--speed-<highway>=<speed> ...] |
217 | [--property-<property>=<preference> ...] |
218 | [--oneway=(0|1)] [--turns=(0|1)] |
219 | [--weight=<weight>] |
220 | [--height=<height>] [--width=<width>] [--length=<length>] |
221 | |
222 | --help |
223 | Prints out the help information. |
224 | |
225 | --help-profile |
226 | Prints out the selected transport profile (type, speed limits, |
227 | highway preferences etc.) |
228 | |
229 | --help-profile-xml |
230 | Prints out all the loaded profiles as an XML file in the same |
231 | format that can be loaded in. |
232 | |
233 | --help-profile-json |
234 | Prints out all the loaded profiles in JavaScript Object Notation |
235 | (JSON) format for use in the interactive webpage. |
236 | |
237 | --help-profile-perl |
238 | Prints out all the loaded profiles as a Perl object for use in |
239 | the router CGI. |
240 | |
241 | --dir=<dirname> |
242 | Sets the directory name in which to read the local database. |
243 | Defaults to the current directory. |
244 | |
245 | --prefix=<name> |
246 | Sets the filename prefix for the files in the local database. |
247 | Defaults to no prefix. |
248 | |
249 | --profiles=<filename> |
250 | Sets the filename containing the list of routing profiles in XML |
251 | format. If the file doesn't exist then dirname, prefix and |
252 | "profiles.xml" will be combined and used, if that doesn't exist |
253 | then the file '/usr/local/share/routino/profiles.xml' (or custom |
254 | installation location) will be used. |
255 | |
256 | --translations=<filename> |
257 | Sets the filename containing the list of translations in XML |
258 | format for the output files. If the file doesn't exist then |
259 | dirname, prefix and "translations.xml" will be combined and |
260 | used, if that doesn't exist then the file |
261 | '/usr/local/share/routino/translations.xml' (or custom |
262 | installation location) will be used. |
263 | |
264 | --exact-nodes-only |
265 | When processing the specified latitude and longitude points only |
266 | select the nearest node instead of finding the nearest point |
267 | within a segment (quicker but less accurate unless the points |
268 | are already near nodes). |
269 | |
270 | --loggable |
271 | Print progress messages that are suitable for logging to a file; |
272 | normally an incrementing counter is printed which is more |
273 | suitable for real-time display than logging. |
274 | |
275 | --quiet |
276 | Don't generate any screen output while running (useful for |
277 | running in a script). |
278 | |
279 | --language=<lang> |
280 | Select the language specified from the file of translations. If |
281 | this option is not given and the file exists then the first |
282 | language in the file will be used. If this option is not given |
283 | and no file exists the compiled-in default language (English) |
284 | will be used. |
285 | |
286 | --output-html |
287 | --output-gpx-track |
288 | --output-gpx-route |
289 | --output-text |
290 | --output-text-all |
291 | Generate the selected output file formats (HTML, GPX track file, |
292 | GPX route file, plain text route and/or plain text with all |
293 | nodes). If no output is specified then all are generated, |
294 | specifying any automatically disables those not specified. |
295 | |
296 | --output-none |
297 | Do not generate any output or read in any translations files. |
298 | |
299 | --profile=<name> |
300 | Specifies the name of the profile to use. |
301 | |
302 | --transport=<transport> |
303 | Select the type of transport to use, <transport> can be set to: |
304 | |
305 | + foot = Foot |
306 | + horse = Horse |
307 | + wheelchair = Wheelchair |
308 | + bicycle = Bicycle |
309 | + moped = Moped (Small motorcycle, limited speed) |
310 | + motorcycle = Motorcycle |
311 | + motorcar = Motorcar |
312 | + goods = Goods (Small lorry, van) |
313 | + hgv = HGV (Heavy Goods Vehicle - large lorry) |
314 | + psv = PSV (Public Service Vehicle - bus, coach) |
315 | |
316 | Defaults to 'motorcar', this option also selects the default |
317 | profile information if the '--profile' option is not given and a |
318 | profile matching the transport name is found. |
319 | |
320 | --shortest |
321 | Find the shortest route between the waypoints. |
322 | |
323 | --quickest |
324 | Find the quickest route between the waypoints. |
325 | |
326 | --lon1=<longitude>, --lat1=<latitude> |
327 | --lon2=<longitude>, --lat2=<latitude> |
328 | ... --lon99=<longitude>, --lat99=<latitude> |
329 | The location of the waypoints that make up the start, middle and |
330 | end points of the route. Up to 99 waypoints can be specified and |
331 | the route will pass through each of the specified ones in |
332 | sequence. The algorithm will use the closest node or point |
333 | within a segment that allows the specified traffic type. |
334 | |
335 | --heading=<bearing> |
336 | Specifies the initial direction of travel at the start of the |
337 | route (from the lowest numbered waypoint) as a compass bearing |
338 | from 0 to 360 degrees. |
339 | |
340 | --highway-<highway>=<preference> |
341 | Selects the percentage preference for using each particular type |
342 | of highway. The value of <highway> can be selected from: |
343 | |
344 | + motorway = Motorway |
345 | + trunk = Trunk |
346 | + primary = Primary |
347 | + secondary = Secondary |
348 | + tertiary = Tertiary |
349 | + unclassified = Unclassified |
350 | + residential = Residential |
351 | + service = Service |
352 | + track = Track |
353 | + cycleway = Cycleway |
354 | + path = Path |
355 | + steps = Steps |
356 | + ferry = Ferry |
357 | |
358 | Default value depends on the profile selected by the --transport |
359 | option. |
360 | |
361 | --speed-<highway>=<speed> |
362 | Selects the speed limit in km/hour for each type of highway. |
363 | Default value depends on the profile selected by the --transport |
364 | option. |
365 | |
366 | --property-<property>=<preference> |
367 | Selects the percentage preference for using each particular |
368 | highway property The value of <property> can be selected from: |
369 | |
370 | + paved = Paved (suitable for normal wheels) |
371 | + multilane = Multiple lanes |
372 | + bridge = Bridge |
373 | + tunnel = Tunnel |
374 | + footroute = A route marked for foot travel |
375 | + bicycleroute = A route marked for bicycle travel |
376 | |
377 | Default value depends on the profile selected by the --transport |
378 | option. |
379 | |
380 | --oneway=[0|1] |
381 | Selects if the direction of oneway streets are to be obeyed |
382 | (useful to not obey them when walking). Default value depends on |
383 | the profile selected by the --transport option. |
384 | |
385 | --turns=[0|1] |
386 | Selects if turn restrictions are to be obeyed (useful to not |
387 | obey them when walking). Default value depends on the profile |
388 | selected by the --transport option. |
389 | |
390 | --weight=<weight> |
391 | Specifies the weight of the mode of transport in tonnes; ensures |
392 | that the weight limit on the highway is not exceeded. Default |
393 | value depends on the profile selected by the --transport option. |
394 | |
395 | --height=<height> |
396 | Specifies the height of the mode of transport in metres; ensures |
397 | that the height limit on the highway is not exceeded. Default |
398 | value depends on the profile selected by the --transport option. |
399 | |
400 | --width=<width> |
401 | Specifies the width of the mode of transport in metres; ensures |
402 | that the width limit on the highway is not exceeded. Default |
403 | value depends on the profile selected by the --transport option. |
404 | |
405 | --length=<length> |
406 | Specifies the length of the mode of transport in metres; ensures |
407 | that the length limit on the highway is not exceeded. Default |
408 | value depends on the profile selected by the --transport option. |
409 | |
410 | The meaning of the <preference> parameter in the command line options |
411 | is slightly different for the highway preferences and the property |
412 | preferences. For the highway preference consider the choice between two |
413 | possible highways between the start and finish when looking for the |
414 | shortest route. If highway A has a preference of 100% and highway B has |
415 | a preference of 90% then highway A will be chosen even if it is up to |
416 | 11% longer (100/90 = 111%). For the highway properties each highway |
417 | either has a particular property or not. If the preference for the |
418 | property is 60% then a highway with the property has a preference of |
419 | 77% (sqrt(60%)) and one without has a preference of 63% |
420 | (sqrt(100-60%)). A highway with the property will be chosen even if it |
421 | is up to 22% longer than one without the property (77/63 = 122%). The |
422 | overall preference for each highway segment is the product of the |
423 | preference for the highway type and all of the preferences for the |
424 | highway properties. |
425 | |
426 | Example usage (motorcycle journey, scenic route, not very fast): |
427 | |
428 | router --dir=data --prefix=gb --transport=motorcycle --highway-motorway=0 \ |
429 | --highway-trunk=0 --speed-primary=80 --speed-secondary=80 --quickest |
430 | |
431 | This will use the files 'data/gb-nodes.mem', 'data/gb-segments.mem' and |
432 | 'data/gb-ways.mem' to find the quickest route by motorcycle not using |
433 | motorways or trunk roads and not exceeding 80 km/hr. |
434 | |
435 | |
436 | filedumper |
437 | ---------- |
438 | |
439 | This program is used to extract statistics from the database, extract |
440 | particular information for visualisation purposes or for dumping the |
441 | database contents. |
442 | |
443 | Usage: filedumper [--help] |
444 | [--dir=<dirname>] [--prefix=<name>] |
445 | [--statistics] |
446 | [--visualiser --latmin=<latmin> --latmax=<latmax> |
447 | --lonmin=<lonmin> --lonmax=<lonmax> |
448 | --data=<data-type>] |
449 | [--dump [--node=<node> ...] |
450 | [--segment=<segment> ...] |
451 | [--way=<way> ...] |
452 | [--turn-relation=<relation> ...] |
453 | [--errorlog=<number> ...]] |
454 | [--dump-osm [--no-super] |
455 | [--latmin=<latmin> --latmax=<latmax> |
456 | --lonmin=<lonmin> --lonmax=<lonmax>]] |
457 | [--dump--visualiser [--data=node<node>] |
458 | [--data=segment<segment>] |
459 | [--data=turn-relation<rel>] |
460 | [--data=errorlog<number>]] |
461 | |
462 | --help |
463 | Prints out the help information. |
464 | |
465 | --dir=<dirname> |
466 | Sets the directory name in which to read the local database. |
467 | Defaults to the current directory. |
468 | |
469 | --prefix=<name> |
470 | Sets the filename prefix for the files in the local database. |
471 | |
472 | --statistics |
473 | Prints out statistics about the database files. |
474 | |
475 | --visualiser |
476 | Selects a data visualiser mode which will output a set of data |
477 | according to the other parameters below. |
478 | |
479 | --latmin=<latmin> --latmax=<latmax> |
480 | The range of latitudes to print the data for. |
481 | |
482 | --lonmin=<lonmin> --lonmax=<lonmax> |
483 | The range of longitudes to print the data for. |
484 | |
485 | --data=<data-type> |
486 | The type of data to output, <data-type> can be selected |
487 | from: |
488 | |
489 | o junctions = segment count at each junction. |
490 | o super = super-node and super-segments. |
491 | o oneway = oneway segments. |
492 | o highway-* = segments of the specified highway type (e.g. |
493 | highway-primary to display segments ofprimary roads). |
494 | o transport-* = segments allowing the specified transport |
495 | type (e.g. transport-foot to display segments accessible |
496 | on foot). |
497 | o turns = turn restrictions. |
498 | o speed = speed limits. |
499 | o weight = weight limits. |
500 | o height = height limits. |
501 | o width = width limits. |
502 | o length = length limits. |
503 | o property-* = segments having the specified property (e.g. |
504 | property-paved to display segments of paved highway). |
505 | o errorlogs = errors logged during parsing. |
506 | |
507 | --dump |
508 | Selects a data dumping mode which allows looking at individual |
509 | items in the databases (specifying 'all' instead of a number |
510 | dumps all of them). More than one of the following parameters |
511 | can be specified on the command line. |
512 | |
513 | --node=<node> |
514 | Prints the information about the selected node number |
515 | (internal number, not the node id number in the original |
516 | source file). |
517 | |
518 | --segment=<segment> |
519 | Prints the information about the selected segment number. |
520 | |
521 | --way=<way> |
522 | Prints the information about the selected way number |
523 | (internal number, not the way id number in the original |
524 | source file). |
525 | |
526 | --turn-relation=<relation> |
527 | Prints the information about the selected turn relation |
528 | number (internal number, not the relation id number in the |
529 | original source file). |
530 | |
531 | --errorlog=<number> |
532 | Prints the information about the selected error log that |
533 | was stored when the data was parsed. |
534 | |
535 | --osm-dump |
536 | Dumps the contents of the database as an OSM format XML file, |
537 | the whole database will be dumped unless the latitude and |
538 | longitude ranges are specified. |
539 | |
540 | --no-super |
541 | The super segments will not be output. |
542 | |
543 | --latmin=<latmin> --latmax=<latmax> |
544 | The range of latitudes to dump the data for. |
545 | |
546 | --lonmin=<lonmin> --lonmax=<lonmax> |
547 | The range of longitudes to dump the data for. |
548 | |
549 | --dump-visualiser |
550 | Dumps the contents of the database as HTML formatted items for |
551 | display in the visualiser web page. |
552 | |
553 | --data=node<node> |
554 | Prints the information about the selected node number |
555 | (internal node number, not from the original source file). |
556 | |
557 | --data=segment<segment> |
558 | Prints the information about the selected segment number |
559 | as if it was a way (internal segment number, unrelated to |
560 | original source file). |
561 | |
562 | --data=turn-relation<relation> |
563 | Prints the information about the selected turn relation |
564 | number (internal turn relation number, not from the |
565 | original source file). |
566 | |
567 | --data=errorlog<number> |
568 | Prints the information about the selected error log that |
569 | was stored when the data was parsed. |
570 | |
571 | filedumperx |
572 | ----------- |
573 | |
574 | This program is a modified version of filedumper that will dump out the |
575 | contents of the intermediate data that is saved by planetsplitter after |
576 | processing using the --keep or --changes option. This is intended |
577 | for test purposes only and gives no useful information about the |
578 | routing database. |
579 | |
580 | Usage: filedumperx [--help] |
581 | [--dir=<dirname>] [--prefix=<name>] |
582 | [--dump [--nodes] |
583 | [--ways] |
584 | [--route-relations] |
585 | [--turn-relations]] |
586 | |
587 | --help |
588 | Prints out the help information. |
589 | |
590 | --dir=<dirname> |
591 | Sets the directory name in which to read the local database. |
592 | Defaults to the current directory. |
593 | |
594 | --prefix=<name> |
595 | Sets the filename prefix for the files in the local database. |
596 | |
597 | --dump |
598 | Dumps the complete set of data in the intermediate files that |
599 | are written by planetsplitter using the --keep or --changes |
600 | options. |
601 | |
602 | --nodes |
603 | Dumps the node data. |
604 | |
605 | --ways |
606 | Dumps the way data. |
607 | |
608 | --route-relations |
609 | Dumps the route relation data. |
610 | |
611 | --turn-relations |
612 | Dumps the turn relation data. |
613 | |
614 | |
615 | -------- |
616 | |
617 | Copyright 2008-2013 Andrew M. Bishop. |
Properties
Name | Value |
---|---|
cvs:description | Description of program usage. |