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 2141 - (show annotations) (download)
Tue Jun 6 18:05:10 2023 UTC (22 months, 1 week ago) by amb
File MIME type: text/plain
File size: 26914 byte(s)
Change the default amount of sorting RAM from 64 or 256 MB to 256 or 1024 MB.

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

Properties

Name Value
cvs:description Description of program usage.