BigQuery API and MIMIC data #1154
-
Greetings! We're trying to setup access the to the MIMIC III data into a Python environment. We're familiar with MIMIC, and with BigQuery cloud access to that data, but we're now trying to invoke it from within Python, using the BigQuery API. Can anyone confirm that one can do this? Once we know it is possible, then we can more seriously chase down bugs. We're stuck at the step where you do "from google.cloud import bigquery" -- at this point, we get an error message claiming no such module... Thanks in advance! -John Gennari & Shivank Mistry |
Beta Was this translation helpful? Give feedback.
Replies: 5 comments 23 replies
-
This is more BigQuery issue then MIMICs if I understand correctly. This is the instruction from BigQuery docs that's relevant. If you haven't been to BigQuery console, I find it great place to begin and see that your user has the proper access for starters. Hope I understood the situation correctly, GL |
Beta Was this translation helpful? Give feedback.
-
Hi @jhgennari
Yes, connecting to BigQuery from a Python Notebook is certainly possible (and it's my favored way of working with MIMIC, eICU-CRD, etc). The easiest way to get started is using Google Colab. You could use one of our SCCM Datathon notebooks as reference: https://github.com/MIT-LCP/sccm-datathon. The steps below outline the process for connecting from a Colab Notebook:
My guess is that you are attempting to connect to BigQuery from a local Python environment (rather than a cloud environment) and that you do not have BigQuery package/tools installed. The process would be similar to the above once the BigQuery tools are installed. For instructions on installing the BigQuery tools locally, see: https://googleapis.dev/python/bigquery/latest/index.html (essentially you need to run: |
Beta Was this translation helpful? Give feedback.
-
Any update on this? |
Beta Was this translation helpful? Give feedback.
-
The process for pinning a project on BigQuery has recently changed. See: #1453 for a step-by-step description of the new process. |
Beta Was this translation helpful? Give feedback.
-
Hello everyone! I have a question on this topic that I'm having a hard time finding a solution to. I intend to perform queries to MIMIC-IV from a local node to speed up the data processing with multiple CPU (derived tables are not sufficient for my objectives). I believe I have set up everything using the available tutorials (access the dataset, billing account).
I have also tried the I'm new to BigQuery so I wonder if anyone has an idea how to address this issue, or if it's not possible. I read the comments above but I couldn't find a solution. Thanks for the help! |
Beta Was this translation helpful? Give feedback.
This is more BigQuery issue then MIMICs if I understand correctly.
I successfully tried with nodejs and not python, but the basics are the same.
This is the instruction from BigQuery docs that's relevant.
If you haven't been to BigQuery console, I find it great place to begin and see that your user has the proper access for starters.
Hope I understood the situation correctly, GL