add via_ip.estimate_location using binary search
This commit is contained in:
parent
7aed18042d
commit
0a48393589
5 changed files with 84 additions and 24 deletions
|
@ -66,17 +66,18 @@ class google:
|
|||
|
||||
|
||||
from typing import Sequence, Union, Tuple
|
||||
from datetime import datetime, date
|
||||
from datetime import datetime, date, timedelta
|
||||
DateIsh = Union[datetime, date, str]
|
||||
LatLon = Tuple[float, float]
|
||||
class location:
|
||||
# todo ugh, need to think about it... mypy wants the type here to be general, otherwise it can't deduce
|
||||
# and we can't import the types from the module itself, otherwise would be circular. common module?
|
||||
home: Union[LatLon, Sequence[Tuple[DateIsh, LatLon]]] = (1.0, -1.0)
|
||||
home_accuracy = 1000.0
|
||||
home_accuracy = 30_000.0
|
||||
|
||||
class via_ip:
|
||||
accuracy: float
|
||||
for_duration: timedelta
|
||||
|
||||
class gpslogger:
|
||||
export_path: Paths = ''
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue