Special graph data-structure that is identical to FastGraph except that it uses u32 integers
instead of usize integers. This is used to store a FastGraph in a 32bit representation on disk
when using a 64bit system.
Creates a PathCalculator that can be used to run many shortest path calculations in a row.
This is the preferred way to calculate shortest paths in case you are calculating more than
one path. Use one PathCalculator for each thread.
When deserializing a FastGraph in a larger struct, use #[serde(deserialize_with = "fast_paths::deserialize_32)]` to transform the graph from a 32-bit representation to the
current platform’s supported size. This is necessary when serializing on a 64-bit system and
deserializing on a 32-bit system, such as WASM.
Prepares the given input graph using a fixed node ordering, which can be any permutation
of the node ids. This can be used to speed up the graph preparation if you have done
it for a similar graph with an equal number of nodes. For example if you have changed some
of the edge weights only.
When serializing a FastGraph in a larger struct, use #[serde(serialize_with = "fast_paths::serialize_32)]` to transform the graph to a 32-bit representation. This will use
50% more RAM than serializing without transformation, but the resulting size will be 50% less.
It will panic if the graph has more than 2^32 nodes or edges or values for weight.