Routino SVN Repository Browser

Check out the latest version of Routino: svn co http://routino.org/svn/trunk routino

ViewVC logotype

Contents of /trunk/doc/USAGE.txt

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1797 - (show annotations) (download)
Wed Sep 9 18:38:46 2015 UTC (9 years, 7 months ago) by amb
File MIME type: text/plain
File size: 26797 byte(s)
Add a '--version' option to all executables to print the current
version (defined in version.h).

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

Properties

Name Value
cvs:description Description of program usage.