consbio / tpkutils

ArcGIS Tile Package Utilities
Other
112 stars 28 forks source link

create tilepackage from CreateMapTilePackage_management error! #15

Closed blinters closed 7 years ago

blinters commented 7 years ago

I found out that create tile package from arcgis tools -> create map tile package doesnt work with tpkutils. Any idea why? this way of creating maptile package is indeed faster than file->share as->tile package.

reference -> http://desktop.arcgis.com/en/arcmap/10.3/tools/data-management-toolbox/create-map-tile-package.htm

any help is much appreciated!

brendan-ward commented 7 years ago

@blinters It could be that some of the options available when using the tool version are not correctly handled by tpkutils. Does tpkutils raise exceptions on the command line? How are you using it - command line or Python API?

Is it possible for you to post a couple small sample files (e.g., zoom levels < 2): one based on using the tool, and one based on using the "file->share as" workflow?

blinters commented 7 years ago

@brendan-ward 1)This is the arcpy code that I call to create a tile package as shown below: createtilepackage

2) this is the error msg when I run the .tpk using tpkutil

tpkutil_bug

3) this is how i call the tpkutil package

code

hope to hear from your reply!

cheers Blinters

blinters commented 7 years ago

@brendan-ward for the previous post, it is not related to the "file->share as-> workflow" as it is running well. just that it takes few hours to generate a tile package. if this tpkutil library can leverage on CreateMapTilePackage in arcgis tool management, processing time to generate tile package will be significantly lesser to just 15 minutes.

my concern is whether this tpkutil can be improved to run the tile package generated by CreateMapTilePackage in arcgis tool management. This would definitely help alot of users!

cheers mate

brendan-ward commented 7 years ago

@blinters right - the reason for the request of 2 test files was so that I could compare them to see how they differ, and figure out why one version breaks. I wanted to compare a known working version against the one that is not, but otherwise only different in terms of the tool used to generate them.

I don't always have ready access (or time) to generate test files in ArcGIS...

brendan-ward commented 7 years ago

@blinters I created a couple test files and will dig into this later.

brendan-ward commented 7 years ago

@blinters it looks like you are using Python 2.7, since you are failing on the sqlite file open statement, not in something related to the actual TPK. Is that indeed the version of python you are using?

Is it possible you are using the ArcGIS 10.3 version of python (which is 2.7) for tpkutils when you export via the tool, but using python 3.x when you export via share?

See #13

brendan-ward commented 7 years ago

Forgot to mention - I created test files using both the share method and the tool method, and they both work fine with tpkutils on python 3.5.

blinters commented 7 years ago

@brendan-ward it actually failed in 10.3 but somehow it works on 10.5 both running on python 3.5!. Anyway thanks for your assistance and great help!

Just a quick question, have you know of any github library that can host/convert arcgis vector tile package .vtpk to other useful format? and that it can be self-hosted?

brendan-ward commented 7 years ago

@blinters I do not know of any tools that convert arcgis vector tile packages. The best target format would be the mapbox vector tile specification: https://www.mapbox.com/vector-tiles/specification/

We have a go-based server for self-hosting mbtiles files, containing either image tiles or vector tiles (according to the mapbox vector tile spec): https://github.com/consbio/mbtileserver