Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

key error when collating results from shorter monitoring periods #157

Open
smallsr opened this issue May 8, 2021 · 0 comments
Open

key error when collating results from shorter monitoring periods #157

smallsr opened this issue May 8, 2021 · 0 comments

Comments

@smallsr
Copy link
Member

smallsr commented May 8, 2021

A key error consistently occurs when using accUtils.collateJSONfilesToSingleCSV when collating summary files from shorter monitoring periods (e.g. 24 hours or less). Interestingly, a workaround is to place a single summary json from a longer monitoring time into the folder with the shorter summary json files. This extra file must have been processed with the same activity model as the current files of interest. When this extra summary file is in place, the script runs without error.
The key error is below:

accUtils.collateJSONfilesToSingleCSV("full_clemson_results/summary/", "xyz.csv")
Traceback (most recent call last):
File "", line 1, in
File "/mnt/c/Users/srsma/mar2021_biobankAccelerometerAnalysis/biobankAccelerometerAnalysis/accelerometer/accUtils.py", line 241, in collateJSONfilesToSingleCSV
dAcc = df[list(refColumnItem.keys())] #maintain intended column ordering
AttributeError: 'NoneType' object has no attribute 'keys'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant