1OSMIUM-ADD-LOCATIONS-TO-WAYS(1)                OSMIUM-ADD-LOCATIONS-TO-WAYS(1)
2
3
4

NAME

6       osmium-add-locations-to-ways - add node locations to ways in OSM file
7

SYNOPSIS

9       osmium add-locations-to-ways [OPTIONS] OSM-FILE...
10

DESCRIPTION

12       Usually only nodes have locations and the ways refer to those locations
13       via the IDs of the nodes.  This program will copy the input file(s)  to
14       the  output, taking the locations from the nodes and adding them to the
15       ways.  This makes it easier for other  programs  to  assemble  the  way
16       geometries.
17
18       The  input  file  must contain all nodes needed for the ways, otherwise
19       there will be an error.   You  can  change  this  behaviour  using  the
20       --ignore-missing-nodes option.
21
22       Nodes   without   any   tags   will   not   be   copied   (unless   the
23       --keep-untagged-nodes/-n option is used).  The size of the output  file
24       will  be  similar  or  a  bit  smaller  than the input file (unless the
25       --keep-untagged-nodes/-n option is used in which case it will be a  lot
26       bigger).
27
28       Note  that  the  OSM files generated by this command use a non-standard
29       format extension.
30
31       The osmium add-locations-to-ways command has to keep an  index  of  the
32       node locations in memory or in a temporary file on disk while doing its
33       work.  There are several different ways it can do that which have  dif‐
34       ferent  advantages  and  disadvantages.  The default is good enough for
35       most cases, but see the osmium-index-types(5) man page for details.
36
37       If the --keep-untagged-nodes/-n option is used, files created  by  this
38       command can be updated with the apply-changes command using the --loca‐
39       tions-on-ways option.
40
41       This command will not work on full history files.
42
43       This commands reads its input file(s) only once and writes  its  output
44       file  in  one go so it can be streamed, ie.  it can read from STDIN and
45       write to STDOUT.
46

OPTIONS

48       -i, --index-type=TYPE
49              Set the index type.  For details see  the  osmium-index-types(5)
50              man page.
51
52       -I, --show-index-types
53              Shows  a  list  of  available  index types.  For details see the
54              osmium-index-types(5) man page.
55
56       -n, --keep-untagged-nodes
57              Keep the untagged nodes in the output file.
58
59       --ignore-missing-nodes
60              If this is not set a missing node needed for a way results in an
61              error.  If this is set, errors are ignored and the way will have
62              an invalid location set for the missing node.
63

COMMON OPTIONS

65       -h, --help
66              Show usage help.
67
68       -v, --verbose
69              Set verbose mode.  The program  will  output  information  about
70              what it is doing to STDERR.
71
72       --progress
73              Show  progress bar.  Usually a progress bar is only displayed if
74              STDOUT and STDERR are detected to be TTY.  With  this  option  a
75              progress  bar  is  always  shown.  Note that a progress bar will
76              never be shown when reading from STDIN or a pipe.
77
78       --no-progress
79              Do not show progress bar.  Usually a progress bar  is  displayed
80              if STDOUT and STDERR are detected to be a TTY.  With this option
81              the progress bar is suppressed.  Note that a progress  bar  will
82              never be shown when reading from STDIN or a pipe.
83

INPUT OPTIONS

85       -F, --input-format=FORMAT
86              The  format  of the input file(s).  Can be used to set the input
87              format if it can’t be autodetected from the file name(s).   This
88              will  set the format for all input files, there is no way to set
89              the format for some  input  files  only.   See  osmium-file-for‐
90              mats(5) or the libosmium manual for details.
91

OUTPUT OPTIONS

93       -f, --output-format=FORMAT
94              The  format  of  the output file.  Can be used to set the output
95              file format if it can’t be autodetected  from  the  output  file
96              name.   See  osmium-file-formats(5)  or the libosmium manual for
97              details.
98
99       --fsync
100              Call fsync after writing the output file to force flushing  buf‐
101              fers to disk.
102
103       --generator=NAME
104              The  name and version of the program generating the output file.
105              It will be added to the header of the output file.   Default  is
106osmium/” and the version of osmium.
107
108       -o, --output=FILE
109              Name of the output file.  Default is `-' (STDOUT).
110
111       -O, --overwrite
112              Allow  an  existing  output  file  to  be overwritten.  Normally
113              osmium will refuse to write over an existing file.
114
115       --output-header=OPTION=VALUE
116              Add output header option.  This command line option can be  used
117              multiple  times for different OPTIONs.  See the libosmium manual
118              for a list of available header options.  For some  commands  you
119              can  use  the special format “OPTION!” (ie.  an exclamation mark
120              after the OPTION and no value set) to set the value to the  same
121              as in the input file.
122

DIAGNOSTICS

124       osmium add-locations-to-ways exits with exit code
125
126       0      if everything went alright,
127
128       1      if there was an error processing the data, or
129
130       2      if there was a problem with the command line arguments.
131

MEMORY USAGE

133       osmium  add-locations-to-ways  will  usually keep all node locations in
134       memory.  For larger data files, this can need several tens of GBytes of
135       memory.  See the osmium-index-types(5) man page for details.
136

EXAMPLES

138       Add node locations to an extract keeping all nodes:
139
140              osmium add-locations-to-ways -n -o germany-low.osm.pbf germany.osm.pbf
141
142       Add node locations to a planet file (without untagged nodes):
143
144              osmium add-locations-to-ways -i dense_mmap_array -o planet-low.osm.pbf planet.osm.pbf
145

SEE ALSO

147       · osmium(1), osmium-file-formats(5), osmium-index-types(5)
148
149       · Osmium website (https://osmcode.org/osmium-tool/)
150
152       Copyright (C) 2013-2019 Jochen Topf <jochen@topf.org>.
153
154       License      GPLv3+:     GNU     GPL     version     3     or     later
155       <https://gnu.org/licenses/gpl.html>.  This is free  software:  you  are
156       free  to  change  and  redistribute  it.   There is NO WARRANTY, to the
157       extent permitted by law.
158

CONTACT

160       If you have any questions or  want  to  report  a  bug,  please  go  to
161       https://osmcode.org/contact.html
162

AUTHORS

164       Jochen Topf <jochen@topf.org>.
165
166
167
168                                    1.11.1     OSMIUM-ADD-LOCATIONS-TO-WAYS(1)
Impressum