amplabs-ai / amplabs

AmpLabs helps teams build better batteries.
https://amplabs.ai
9 stars 9 forks source link

Missing Record Error While Running Battery Data Python Scripts #32

Closed wehuang16 closed 1 year ago

wehuang16 commented 1 year ago

When I try to run the Jupyter notebook battery data scripts in the "python" folder, running the scripts both in my local computer and colab. It always causes an error on a missing "Record", as shown below. Capture1213 Capture1214 I guess the error might be because I don't have the correct token, but there might be another issue going on. Could anybody provide some insights on what might have gone wrong while I wan running the battery data scripts?

pghege commented 1 year ago

@wehuang16 You are correct the user_token on line In [4] still has the default text "". You will need to provide your own token which can be fetched from the AmpLabs website. A few takeaways here for development.

  1. Here will have to improve the error that's returned instead of waiting for a failure from the parsing. The API should return 'invalid token' and potentially link to an evergreen doc with instructions on how to fetch their token.
  2. The instructions on the example should make the requirement of a token more clear
  3. Perhaps the demo scripts could have an evergreen 'demo' token that can perform certain limited functionality in order for user to have an early "win"
wehuang16 commented 1 year ago

I went to the "amplabs.ai" website, and clicked "try Amplabs Cloud". Capture2201

I signed up using my email address and logged in to Amplabs Cloud. There, on the top right menu, I clicked "get API token". Screenshot (187)

Then, I copied my token into the Jupyter notebook "ipynb" file to replace the "user_token = '' " line. However, it still shows the error of a missing "records". And the error message seems to suggest the user token has expired. Capture2202

Are there any insights on why the API token I fetched from the Amplabs Cloud didn't work?

wehuang16 commented 1 year ago

Some additional information. I see that with my API token and the correct cell id, the Amplabs Python scripts seems to be able to load medatada successfully, but not successful in loading timeseries data (still have the missing 'records' error) Capture2203 Capture2204

pghege commented 1 year ago

It looks like there was a change in the API definition. We will update the sample scripts to reflect this change. As we rollout the sdk, and implement better versioning, then these issues will reduce. We will fix the examples appropriately.

Hema-Appperfect commented 1 year ago

@wehuang16 updated the scripts