GithubHelp home page GithubHelp logo

matthieuheitz / google-data-analyses Goto Github PK

View Code? Open in Web Editor NEW
54.0 6.0 26.0 8 KB

A repo where I will put my scripts to analyze the data that Google collects about me.

License: MIT License

Python 100.00%

google-data-analyses's Introduction

google-data-analyses

A repo where I will put my scripts to analyze the data that Google collects about me.

google-data-analyses's People

Contributors

matthieuheitz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

google-data-analyses's Issues

Traceback line 75

Loading 'location_history.json' ...
JSON file loaded
Extracting relevant data...
Traceback (most recent call last):
File "get_visit_times.py", line 75, in
accuracy[i] = point['accuracy']
KeyError: 'accuracy'

Traceback on line 74 in get_visit_times

Loading 'location_history.json' ...
JSON file loaded
Extracting relevant data...
Traceback (most recent call last):
File "/home/shurygin/bin/get_visit_times.py", line 74, in
positions[i] = np.array([float(point['latitudeE7']),float(point['longitudeE7'])])/1e7
KeyError: 'latitudeE7'

no points found

Google renamed the json file to Records.json.

Also the timestamp key is renamed. Therefore the total number of points keeps returning zero.

What is the significance of the group size?

Thank you for making this script available. I'm testing it out now and it looks like a very helpful interpretation of the Google Maps location data.

Could you provide some clarification/explanation for how to interpret the "Group of # Points" messages, presumably in the context of the group_size parameter? I can't figure out if the points refer to geographic locations (e.g. a cluster of points near each other in 2D) or timepoints (i.e. a cluster of measurements close to each other in time).

AttributeError: 'datetime.datetime' object has no attribute 'timestamp'

Hello,
New to python and haven't been able to figure this out.
running python 2.7.18 in windows 10 command prompt.
I put the latest error in the title, AttributeError: 'datetime.datetime' object has no attribute 'timestamp' .
but prior to that, I was getting, Traceback (most recent call last):
File "C:\google-data-analyses-master\get_visit_times.py", line 87, in
data.clear()
AttributeError: 'list' object has no attribute 'clear' .
not sure if the two are related. I was able to bypass the clear error by commenting out the #data.clear() line. have lots of memory so figured why not.
the latest error I get is bellow.

C:\google-data-analyses-master>get_visit_times.py
Loading 'C:\google-data-analyses-master\Location History.json' ...
JSON file loaded
Extracting relevant data...
Total number of points: 4171876
Traceback (most recent call last):
File "C:\google-data-analyses-master\get_visit_times.py", line 95, in
begin_ts = date_ymd_to_timestamp_ms(2019,01,01)
File "C:\google-data-analyses-master\get_visit_times.py", line 24, in date_ymd_to_timestamp_ms
return datetime.datetime(y,m,d).timestamp()#*1e3
AttributeError: 'datetime.datetime' object has no attribute 'timestamp'

Distinct dates

This ist great and about perfectly fitting for what I was looking quite a long time. Is there an easy way to get every date listeted only once, so I can get all the dates I've been at work AND how many times that was (I need it for Tax)?
If you say "Just do it yourself, lazy bastard" I am about to learn python to do it myself.
Strange google does not provide a simple way to access these data they are collecting.....

Traceback error - line 73

when executing the script, the following traceback message is received

Traceback (most recent call last):
  File "get_visit_times.py", line 73, in <module>
    accuracy[i] = point['accuracy']
KeyError: 'accuracy'

My json file contains accuracy keys for all objects.
Example: "accuracy" : 30

The only changes made to the script:

  • updated poi with my coordinates from google maps
  • updated begin_ts and end_ts with my date range

Returns 0 close points

The script seems to return 0 close points even after trying multiple different lats and longs and an absurdly large radius. Any ideas why this may be?

SyntaxError

Thank you for your work with this, it would be really useful to have its functionality.

After placing the get_visit_times.py in the same folder as location history.json and after executing the script with "python get_visit_times.py" in terminal it's returning "SyntaxError: invalid syntax".

It's likely that I'm doing something wrong - is there something else I need to do? Maybe would be best to answer this in the readme.

Using Python 3.7.3

How to

First, thank you for writing this. Second, I really don't want to learn Python; I just want to run the script. The first error I got was because I didn't have the json data in the same sub as the script. Solved.
The next error was because numpy was not found. I wanted to install numpy but holy shit, it just ain't easy.

Is there a way to make this more user-friendly? I have the skills but not the patience.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.