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 1201 - (show annotations) (download)
Sat Dec 15 11:58:33 2012 UTC (12 years, 3 months ago) by amb
File MIME type: text/plain
File size: 25813 byte(s)
Add the --logtime and --errorlog options to tagmodifier.

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

Properties

Name Value
cvs:description Description of program usage.