Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve Java decoding benchmark #197

Open
springmeyer opened this issue Jun 25, 2024 · 1 comment
Open

Improve Java decoding benchmark #197

springmeyer opened this issue Jun 25, 2024 · 1 comment

Comments

@springmeyer
Copy link
Collaborator

springmeyer commented Jun 25, 2024

Context

The Java decoding benchmark compares the speed of MLT decoding against two different libraries implementing https://github.com/mapbox/vector-tile-spec:

Problem

Both vector tile libraries are doing extra work that is not representative of what Maplibre needs.

Maplibre needs:

  • "Lightweight layers": decoded layers that store offsets to features and only decode features when accessed by layer.feature(idx).
  • "Lightweight features": decoded features containing just an id, extent, and properties only
  • Then, as needed, Maplibre will call a function on those features called feature.loadGeometry() to on-demand, fetch a two-dimensional Array<Array<Point>> representation of geometries.

Rather what the Java vector tile libraries do are:

ElectronicChartCentre/java-vector-tile

sebasbaumh/mapbox-vector-tile-java

Solution

We need to correct the Java benchmarks to compare against MVT decoding that is representative of what Maplibre expects.

@springmeyer
Copy link
Collaborator Author

MVT decoding that is representative of what Maplibre expects.

@mactrem here is a library in java that can be used to compare against: https://github.com/springmeyer/vector-tile-java. Let me know if you have any questions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant