datetime.keyHash
datetime: key = keyHash (T)
datetime: key = keyHash (T, base)
Generate a hash code for datetime array.
key = keyHash (T) generates a uint64 scalar
that represents the input array T. keyHash utilizes the
64-bit FNV-1a variant of the Fowler-Noll-Vo non-cryptographic hash
function.
key = keyHash (T, base) also generates a 64-bit
hash code using base as the offset basis for the FNV-1a hash
algorithm. base must be a uint64 integer type scalar. Use
this syntax to cascade keyHash on multiple objects for which a
single hash code is required.
A datetime array is keyed on the instant its elements name and
not on their wall clock and time zone, so the same moment expressed in
two zones has the same hash code. An unzoned array, a zoned array and
a leap-second array are three separate frames that never share a key,
whatever instants they name, and the two instants sharing a wall clock
across a daylight-saving fall-back stay distinct. The Format
property is display only and is not part of the key. Two arrays that
keyMatch reports as the same key always hash alike.
Note that unlike MATLAB, this implementation does not use any random
seed. As a result, keyHash will always generate the exact same
hash key for any particular input across different workers and Octave
sessions.
Source Code: datetime