All notable changes to this project will be documented in this file.
The format is loosely based on Keep a Changelog, and this project adheres to Semantic Versioning.
After version 0.12 the version numbers from the individual crates are decoupled from each other as releases are now
done without github actions and without having to coordinate the release process with the h3ronpy
python extension.
- Upgraded
geo
to 0.27 - Upgraded
indexmap
to 2 andhashbrown
to 0.14 - Upgrade h3ron-h3-sys to 0.17
ToIntersectingH3Cells
trait and implementations forPolygon
andMultiPolygon
.
- Upgrade hashbrown to 0.13
- Upgrade h3ron-h3-sys to 0.16
- Add example describing how to compile to the wasm32-wasi target.
- Parse
H3Cell
from different string representations usingH3Cell::from_str
. #52 ToLine
trait and implementation forH3DirectedEdge
.- Added
h3ron::algorithm::find_cell_clusters
andh3ron::algorithm::find_cell_clusters_eq_value
.
- Use only types from
geo-types
in the public API, not fromgeo
. - Upgrade
geo
from 0.22 to 0.23. - Include pre-build bindings in
h3ron-h3-sys
to drop thebindgen
dependency as the default. Enabling thebindgen
-feature allows creating the bindings during build. - Upgrade
roaring
from 0.9 to 0.10. - Move
polygon_to_cells
andmax_polygon_to_cells_size
toto_h3
module.
- Upgraded
h3ron-h3-sys
to 0.15 to drop thecmake
build time dependency by buildinglibh3
with thecc
crate.
This version includes the migration from H3 version 3.x to 4.x. This includes some renaming of functions and
structs to stay somewhat consistent with the changes made in H3
as well as making most functions return Result<T, Error>
as H3 now returns error codes in most functions of its API.
- Added
H3Treemap::from_result_iter_with_sort
for easier construction from iterators yieldingResult
- Added
H3Cell::center_child
. - Added
IndexBlock::contains
.
h3ron::io
module has been relocated toh3ron_graph:io::serde_util
as it is fairly custom and only used there. Requires theio_serde_util
feature.
-
Migration to H3 v4.0
- Many functions are now failable and return
Result<T, Error>
. - Renaming of functions and structs:
res0_index_count
->res0_cell_count
res0_indexes
->res0_cells
iter::GeoBoundaryBuilder
->iter::CellBoundaryBuilder
max_polyfill_size
->max_polygon_to_cells_size
polyfill
->polygon_to_cells
compact
->compact_cells
line_size
->grid_path_cells_size
line_between_cells
->grid_path_cells
Index
trait- moved all hierarchy traversal functions to
H3Cell
- moved all hierarchy traversal functions to
H3Cell
get_base_cell
->get_base_cell_number
area_m2
->area_avg_m2
area_km2
->area_avg_km2
unidirectional_edges
->directed_edges
is_neighbor_to
->are_neighbor_cells
hex_ring
->grid_ring_unsafe
distance_to
->grid_distance_to
exact_area_m2
->area_m2
exact_area_km2
->area_km2
exact_area_rads2
->area_rads2
hex_range_distances
->grid_disk_distances_unsafe
k_ring_distances
->grid_disk_distances
- The
h3ron::experimantal
module has been renamed toh3ron::localij
. The contained functions have now been added toH3Cell
:H3Cell::to_localij
andH3Cell::from_localij
.
H3Edge
->H3DirectedEdge
edge_length_km
->edge_length_avg_km
edge_length_m
->edge_length_avg_m
cell_centroid_distance_m_at_resolution
->cell_centroid_distance_avg_m_at_resolution
destination_index
->destination_cell
origin_index
->origin_cell
cell_indexes
->cells
- undirectional edge -> directed edge
- Adapted
Error
to the error codes now defined in H3. - Most
*_unchecked
methods are gone now as H3 returns natively error codes.
- Many functions are now failable and return
-
The
ExactArea
trait was removed as it was only implemented forH3Cell
. The methods have been added theH3Cell
. The same forExactLength
andH3Edge
. -
Upgrade
geo
dependency to 0.21. -
Upgrade
roaring
optional dependency to 0.9. -
IndexBlock
now uses the simpler run-length encoding instead of LZ4. Compression ratio stays nearly the same. Feature-gate is removed. This change makes deserialization of previously serialized data impossible -
Upgrade
ahash
dependency to 0.8.
- Add
H3Edge::from_cells
as an alternative way to build edges toH3Cell::unidirectional_edge_to
. - Add
h3ron::iter::continuous_cells_to_edges
. - Add
h3ron::error::InvalidGeometry
error. - Add
H3Direction::iter_directions_over_resolutions
to iterate over all directions leading to the givenIndex
starting from resolution 0 to the resolution of theIndex
. - Add
h3ron::res0_index_count
andh3ron::res0_indexes
. - Add
Index::base_cell_number
. - Add naive implementation of
h3ron::collections::IndexHierarchyMap
as an idea to maybe improve in the future. - Allow faster creation of
H3Treemap
from unsorted iterators by usingH3Treemap::from_iter_with_sort
. - Add
IndexBlock
to storeIndex
vectors in compressed form. This replaces the formerCompressedIndexVec
and also provides a better compression ratio. - Add
h3ron::iter::BoundaryBuilder
andh3ron::iter::GeoBoundaryIter
. SwitchingToPolygon
forH3Cell
to using these. The result is 5-10% reduction in run time. - Add
h3ron::iter::change_resolution_tuple
.
- Re-export
hashbrown
fromcollections
. - switch to using safe en-/decoding with lz4_flex
- Pass function parameters using
Copy
-implementing types likeH3Cell
andH3Edge
directly and not via reference. #26. - Remove the generic hasher parameter from
ThreadPartitionedMap
. Also make the number of partitions not CPU dependent but instead using a generic usize parameter (using const_generics). - Cleanup/rename feature gates - see main page of documentation.
- Switch from using H3
radsToDegs
anddegsToRads
to rustsf64::to_degrees
andf64::to_radians
as this appears slightly faster in benchmarks. - Switch to rust edition 2021
- Rename
change_cell_resolution
tochange_resolution
and make generic over allIndex + FromH3Index
types. This allows usage withH3Cell
andH3Edge
.
- Removal of
CompressedIndexVec
in favour ofIndexBlock
. See the above "Added" section. - Removed
ToLinestring::to_linestring_unchecked
andToMultiLinestring::to_multilinestring
in favour of the checked variants. ThreadPartitionedMap
has been removed.
IndexVec<T>
to interface between libh3 and rust.H3EdgesBuilder
:Creates H3Edges from cells while only requiring a single memory allocation when the struct is created.KRingBuilder
for repeated creation of small k-rings while avoiding allocations for each cell.neighbors_within_distance_window_or_default
iterator including a few simplified wrapper functions.- add
CompactedCellVec::shrink_to_fit
- added specialized collections based on
hashbrown
withahash
hashing. AddedThreadPartionedMap
behinduse-rayon
feature. HasH3Resolution
traitH3Edge::cell_indexes
andH3Edge::cell_indexes_unchecked
to get the origin and destination cell of an edge in one call.H3Edge::reversed
andH3Edge::reversed_unchecked
to get the edge in the reverse direction.ContainsIndex
trait for collections.ToMultiLineString
trait for&[H3Edge]
andVec<H3Edge>
.- Implemented
Deref
forH3Cell
andH3Edge
#23. - All types implementing
Index
can have directions #23. - Add
H3Edge::boundary_linestring
. - Add
H3Edge::cell_centroid_distance_m
andH3Edge::cell_centroid_distance_m_at_resolution
.
- Changed many return values from
Vec
toIndexVec
to reduce the number of allocations by doing less moving around ofH3Index
types. - Clean up measurement functions. Create
ExactArea
andExactLength
traits and move the measurement functions fromH3Cell
andH3Edge
to these traits. RemoveAreaUnits
and move average-area functions toH3Cell
. - Fixed overflow in
H3Direction
#23. - Make serde support feature-gated behind
use-serde
.
h3ron 0.12.0 - 2021-08-10
change_cell_resolution
iterator
- dependency updates
- Using
repr(transparent)
forH3Cell
andH3Edge
types. - Removing
H3Index
from most of the API:- Changing all functions from
H3Index
parameters and return values toH3Cell
/H3Edge
. In the names of the functions the term "index" has also been replaced. - Replacing the
ToH3Indexes
trait withToH3Cells
- Changed
H3CompactedVec
toCompactedCellVec
- Changing all functions from
- Make
CompactedCellVec::add_cells
take a generic iterator and removeadd_indexes_from_iter
. - remove
FromIterator<H3Index> for CompactedCellVec
h3ron 0.11.0 - 2021-06-12
Debug
trait implementations forH3Cell
andH3Edge
to display theH3Index
in hexadecimal. #16ToLineString
trait providingto_linestring
andto_linestring_unchecked
methods to convertH3Edge
to ageo-types
LineString<f64>
.
- Update dependencies:
geo-types
0.6->0.7
h3ron 0.10.0 - 2021-04-24
- Edge indexes (named
H3Cell
) with edge length methods, validation, getting an edge between two hexagons. #10, #11- Edges can retrieve their origin and destination hexagons.
- Get a hexagons edges.
- Implementation of the relative H3 direction system (see https://h3geo.org/docs/core-library/h3Indexing) . #13
- Implementing
Add
andSub
traits forCoordIj
. #9
- Changing
Index
to a trait, the formerIndex
renamed toH3Cell
. #10 , #11, #15 - Error handling improvements. #10 , #11
- Renaming
CoordIJ
toCoordIj
andError::NoLocalIJCoordinates
toError::NoLocalIjCoordinates
to follow clippy suggestions.
h3ron 0.9.0 - 2021-04-11
TryFrom
implementation to convertu64
toIndex
- Improved documentation. #8 , #6
ToH3
-trait to convertgeotypes
geometries to H3Vec
instances.
- Extending unittest for
CoordIJ
- Fixing new clippy warnings after the upgrade to rust 1.51
- Introducing more checks in the API when traversing parent indexes and creating indexes from coordinates. #8
- Improved index validation and error handling.
- removed
From
implementation to convertu64
toIndex
The changes done in earlier versions where not documented in this changelog and can only be reconstructed from the commits in git.