Jupyter Notebook Apache-2.0

python-docs-samples

Code samples used on cloud.google.com

G

GoogleCloudPlatform

Dernière activité 28 sept. 2026
GoogleCloudPlatform/python-docs-samples

8,1 k

étoiles

6,7 k

forks

101

issues ouvertes

pythonsamples

Ce README est souvent en anglais.

Google Cloud Platform Python Samples

Python samples for Google Cloud Platform products.

Google Cloud Samples

Check out some of the samples found on this repository on the Google Cloud Samples page.

Setup

  1. Install pip and virtualenv if you do not already have them.

  2. Clone this repository:

    git clone https://github.com/GoogleCloudPlatform/python-docs-samples.git
    
  3. Obtain authentication credentials.

    Create local credentials by running the following command and following the oauth2 flow (read more about the command here):

    gcloud auth application-default login
    

    Read more about Google Cloud Platform Authentication.

How to run a sample

  1. Change directory to one of the sample folders, e.g. logging/cloud-client:

    cd logging/cloud-client/
    
  2. Create a virtualenv. Samples are compatible with Python 3.6+.

    python3 -m venv env
    source env/bin/activate
    
  3. Install the dependencies needed to run the samples.

    pip install -r requirements.txt
    
  4. Run the sample:

    python snippets.py
    

Contributing

Contributions welcome! See the Contributing Guide.

Projets similaires

Code samples for using Python on Google Cloud Platform

Pythonsamples
GGoogleCloudPlatform
820 étoiles571

Java and Kotlin Code samples used on cloud.google.com

Javaappengineauthautoml
GGoogleCloudPlatform
1,9 k étoiles2,9 k

TensorFlow examples

Jupyter Notebooktensorflowtensorflow-examples
Ttensorflow
8,3 k étoiles7,3 k