Hi Enrico,

I use osmconvert like this in a script:
set input=f:\osm\niedersachsen-latest.osm.pbf
...
rmdir /s/q split
if not exist part.o5m f:\osm\osmconvert --drop-author -B=map.poly %input% 
-o=part.o5m
if not exist srtm.o5m f:\osm\osmconvert --drop-author -B=map.poly 
f:\osm\Hoehendaten_Freizeitkarte_EUROPE.osm.pbf -o=srtm.o5m
rem merge
if not exist work.o5m f:\osm\osmconvert part.o5m srtm.o5m -o=work.o5m
java -Xmx4G -jar d:\splitter\dist\splitter.jar --output-dir=split 
--max-nodes=1000000 --mapid=%mapid%0001 --write-kml=splitter.kml work.o5m  > 
splitter_%dt%-%t%.log

I create the file map.poly with JOSM (and the poly plugin). Instead of 
niedersachsen-latest.osm.pbf I can also use a larger file like 
europe-latest.osm.pbf if needed.

Gerd

________________________________________
Von: mkgmap-dev <[email protected]> im Auftrag von Enrico 
Liboni <[email protected]>
Gesendet: Mittwoch, 10. Juni 2020 23:52
An: Development list for mkgmap
Betreff: Re: [mkgmap-dev] Osmium or Splitter/mkgmap issue?

Acth...

* osmium sort "...will  take  roughly  10 times as much memory as the files 
take on disk in  osm.pbf format" - thus I can't pursue this  option when 
dealing with several countries :(
* osmconvert seems to need o5m, not pbf... I have all pbfs.



On Wed, Jun 10, 2020 at 10:56 PM Gerd Petermann 
<[email protected]<mailto:[email protected]>> wrote:
Hi Enrico,

I use osmconvert. I am not familar with osmosis and I cannot use osmium on 
Windows.
sort instead of merge sounds good, but I would expect an error message from 
splitter when data is not sorted correctly.
You should also check the output from splitter reg. the bounds.

Gerd

________________________________________
Von: mkgmap-dev 
<[email protected]<mailto:[email protected]>>
 im Auftrag von Enrico Liboni <[email protected]<mailto:[email protected]>>
Gesendet: Mittwoch, 10. Juni 2020 22:49
An: Development list for mkgmap
Betreff: Re: [mkgmap-dev] Osmium or Splitter/mkgmap issue?

Gerd -  however I see no reason why bounds should be different, I use the very 
same ones. By the way, as per my other email, it seems that usong osmium sort 
instead of osmium merge does the trick. Perhaps objects are not sorted as 
osmium merge expects...

What do you usually use to merge pbfs?

Thanks!
Enrico

On Wed, Jun 10, 2020 at 10:27 PM Gerd Petermann 
<[email protected]<mailto:[email protected]><mailto:[email protected]<mailto:[email protected]>>>
 wrote:
Hi Enrico,

maybe the two files 70000001.osm.pbf have different bounds? If one is much 
larger the difference could be the additional data for sea and background 
polygons.
In one command you list the input files, in the other you use *.pbf.

Gerd

________________________________________
Von: mkgmap-dev 
<[email protected]<mailto:[email protected]><mailto:[email protected]<mailto:[email protected]>>>
 im Auftrag von Enrico Liboni 
<[email protected]<mailto:[email protected]><mailto:[email protected]<mailto:[email protected]>>>
Gesendet: Mittwoch, 10. Juni 2020 22:19
An: Development list for mkgmap
Betreff: [mkgmap-dev] Osmium or Splitter/mkgmap issue?

I'm getting a weird behaviour: I merge <5MB pbfs,  when using osmium I get a 
8MB img file while with osmosis it is less than 4MB! The latter seems fine 
since the initial pbfs are less than 5MB. I'd like to use osmium in my scripts 
since it performs better.

Am I doing something wrong? Thanks to anyone that could shed some light on this!

# input pbfs
-r--r-----  1 enrico enrico 4673440 Jun 10 21:50 malta-latest.osm.pbf
-r--r-----  1 enrico enrico   15376 Jun 10 21:50 
Malta_lon14.03_14.74lat35.65_36.00_view3.osm.pbf
-r--r-----  1 enrico enrico    8300 Jun 10 21:50 
Malta_lon14.03_14.74lat36.00_36.18_view3.osm.pbf
# using osmium
$ osmium merge *.pbf -o all.pbf
$ java -jar ../splitter/splitter.jar --mapid=70000001 all.pbf
$ java -jar ../mkgmap/mkgmap.jar  --family-id=10030 --product-id=1  --route 
--remove-short-arcs  --bounds=../bounds.zip \
 --precomp-sea=../sea.zip  --location-autofill=is_in,nearest --draw-priority=20 
--gmapsupp  --index --housenumbers 7000*pbf

-rw-rw-r-- 1 enrico enrico 4695873 Jun 10 21:54 all.pbf
-rw-rw-r-- 1 enrico enrico 4288669 Jun 10 21:54 70000001.osm.pbf
-rw-rw-r-- 1 enrico enrico 7925760 Jun 10 21:55 70000001.img
-rw-rw-r-- 1 enrico enrico 8171520 Jun 10 21:55 gmapsupp.img

# using osmosis
$ ../osmosis/bin/osmosis --rbf ./malta-latest.osm.pbf \
 --rbf ./Malta_lon14.03_14.74lat35.65_36.00_view3.osm.pbf \
 --rbf ./Malta_lon14.03_14.74lat36.00_36.18_view3.osm.pbf \
 --merge --merge --wb all.pbf
$ java -jar ../splitter/splitter.jar --mapid=70000001 all.pbf
$ java -jar ../mkgmap/mkgmap.jar  --family-id=10030 --product-id=1  --route 
--remove-short-arcs  --bounds=../bounds.zip \
 --precomp-sea=../sea.zip  --location-autofill=is_in,nearest --draw-priority=20 
--gmapsupp  --index --housenumbers 7000*pbf

-rw-rw-r--  1 enrico enrico 4680030 Jun 10 22:03 all.pbf
-rw-rw-r--  1 enrico enrico 4288668 Jun 10 22:04 70000001.osm.pbf
-rw-rw-r--  1 enrico enrico 3547136 Jun 10 22:04 70000001.img
-rw-rw-r--  1 enrico enrico 3788800 Jun 10 22:04 gmapsupp.img

Using very latest splitter, mkgmap, and osmium (tried with 1.10 and 1.12 
compiled from source...).
Note both gmapsupp.img seems to work just fine on the garmin device.
_______________________________________________
mkgmap-dev mailing list
[email protected]<mailto:[email protected]><mailto:[email protected]<mailto:[email protected]>>
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
_______________________________________________
mkgmap-dev mailing list
[email protected]<mailto:[email protected]>
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev
_______________________________________________
mkgmap-dev mailing list
[email protected]
http://www.mkgmap.org.uk/mailman/listinfo/mkgmap-dev

Reply via email to