kootenpv / whereami

Uses WiFi signals :signal_strength: and machine learning to predict where you are
GNU Affero General Public License v3.0
5.1k stars 247 forks source link

Support alternative output formats for predict_proba #41

Closed ninowalker closed 2 years ago

ninowalker commented 6 years ago

The system currently prints contents as a Python dictionary, which is a hassle to parse. Adding support for JSON and text outputs.

coveralls commented 6 years ago

Coverage Status

Coverage decreased (-1.8%) to 82.449% when pulling 9e7c3864b9bee7cd252df17a70a92dca496f75aa on ninowalker:master into dfa5f327e62668befaf0f202c017c728784d1301 on kootenpv:master.

coveralls commented 6 years ago

Coverage Status

Coverage decreased (-1.8%) to 82.449% when pulling 9e7c3864b9bee7cd252df17a70a92dca496f75aa on ninowalker:master into dfa5f327e62668befaf0f202c017c728784d1301 on kootenpv:master.

coveralls commented 6 years ago

Coverage Status

Coverage decreased (-1.8%) to 82.449% when pulling 9e7c3864b9bee7cd252df17a70a92dca496f75aa on ninowalker:master into dfa5f327e62668befaf0f202c017c728784d1301 on kootenpv:master.

kootenpv commented 6 years ago

I agree!

Though, would you be okay with only supporting JSON? If someone has a comma in their location it will be annoying to deal with CSV, I don't want to go that road.

We'd just import json, and always json.dumps predict_proba.

kootenpv commented 6 years ago

I made sure to print it to json. Would you be okay with that, or do you have a compelling reason for supporting csv :)?


Changes are visible from whereami==0.4.85 onwards.

# also updates subpackages (recommended)
pip install -U whereami

or

 # only upgrades whereami
 pip uninstall whereami && pip install --no-cache whereami