-
Notifications
You must be signed in to change notification settings - Fork 20
Description
h3-py has multiple index APIs. Currently, H3-Pandas is based on the basic_str API.
For performance, it would make the most sense to work with the numpy_int or memview_int APIs.
I see two options:
Method 1: Provide the user with an option
The user could then choose which API they want, similar to how h3-py does it. They could be informed of the potential speedups with the integer representations.
Method 2: Work always with integers, but show string representations
Most H3 users are arguably familiar with the H3 string representation. A possibility, originally suggested by @ajfriend, might be to utilize Pandas' extension types to provide a class that uses the int representation under the hood, but has a str representation (repr). This would allow the user to stay with the familiar string representation, but use all the performance improvements stemming from the int representation.
I do not know if this is possible in such a way as to still be able to leverage the speedups. This should be investigated.