Git Product home page Git Product logo

vertex-ai-automl-pipeline's Introduction

vertex-ai-automl-pipeline

Vertex AI e2e pipeline with classification problem case using AutoML.

This project is based on the Google's demo which can be found in https://github.com/GoogleCloudPlatform/vertex-ai-samples/blob/main/notebooks/official/pipelines/automl_tabular_classification_beans.ipynb

Folder analysis

  1. config contains the component and pipeline configuration files
  2. components contains veterx component python files
  3. pipelines contains veterx pipeline python files
  4. utils contains helper functions

Set up for running locally

  1. Clone the repository by running

    git clone https://github.com/Rasheed19/vertex-ai-automl-pipeline
    
  2. Navigate to the root folder, i.e., vertex-ai-automl-pipeline and create a python virtual environment by running

    python3.10 -m venv .venv
    
  3. Activate the virtual environment by running

    source .venv/bin/activate
    
  4. Upgrade pip by running

    pip install --upgrade pip
    
  5. Install all the required Python libraries by running

    pip install -r requirements.txt
    
  6. Download the beans data from hhttps://archive.ics.uci.edu/dataset/602/dry+bean+dataset. Convert it to csv and upload it to the BigQuery

  7. Create a file named .env in the root folder and store the following variables related to your GCP:

    PROJECT_ID=your-project-id
    REGION=your-project-region
    BUCKET_URI=gs://your-project-name
    SERVICE_ACCOUNT=your-service-account
    
  8. Run the following commands in your terminal to configure the pipeline run on the Vertex AI (make sure gcloud CLI is installed on your computer):

    1. Login:

      gcloud auth login
      
    2. Configure the login to use your prefered project:

      gcloud config set project your-prpject-id
      
    3. Get and save your user account credentials:

      gcloud auth application-default login
      
    4. Grant access to the pipeline to use your storage bucket

      gsutil iam ch serviceAccount:your-service-account:roles/storage.objectCreator gs://your-project-name
      
      gsutil iam ch user:your-gmail-address:objectCreator gs://your-project-name
      
  9. Then run the pipeline that trains, registers, and deploys a trained model to the Vertex AI endpoint by running one of the following customised commands in your terminal:

    1. Run the pipeline with default options

      python run.py
      
    2. Run the pipeline with Quality Gate for test AU ROC set at 95% for test set. If the threshold fails, then the model won't be deployed to an endpoint.

      python run.py --min-test-accuracy 0.95
      

vertex-ai-automl-pipeline's People

Contributors

rasheed19 avatar

Watchers

 avatar

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.