GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — docs: Add code sample for Pipelines (#684) · googleapis/python-aiplatform@4f0c18e

File tree

Expand file treeCollapse file tree
Open diff view settings
Filter options
  • README.rst
Expand file treeCollapse file tree
Open diff view settings
Collapse file

‎README.rst‎

Copy file name to clipboardExpand all lines: README.rst
+41Lines changed: 41 additions & 0 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -349,6 +349,47 @@ To delete an endpoint:
349349
endpoint.delete()
350350
351351
352+
Pipelines
353+
---------
354+
355+
To create a Vertex Pipeline run:
356+
357+
.. code-block:: Python
358+
359+
# Instantiate PipelineJob object
360+
pl = PipelineJob(
361+
# Display name is required but seemingly not used
362+
# see https://github.com/googleapis/python-aiplatform/blob/9dcf6fb0bc8144d819938a97edf4339fe6f2e1e6/google/cloud/aiplatform/pipeline_jobs.py#L260
363+
display_name="My first pipeline",
364+
365+
# Whether or not to enable caching
366+
# True = always cache pipeline step result
367+
# False = never cache pipeline step result
368+
# None = defer to cache option for each pipeline component in the pipeline definition
369+
enable_caching=False,
370+
371+
# Local or GCS path to a compiled pipeline definition
372+
template_path="pipeline.json",
373+
374+
# Dictionary containing input parameters for your pipeline
375+
parameter_values=parameter_values,
376+
377+
# GCS path to act as the pipeline root
378+
pipeline_root=pipeline_root,
379+
)
380+
381+
# Execute pipeline in Vertex
382+
pl.run(
383+
# Email address of service account to use for the pipeline run
384+
# You must have iam.serviceAccounts.actAs permission on the service account to use it
385+
service_account=service_account,
386+
387+
# Whether this function call should be synchronous (wait for pipeline run to finish before terminating)
388+
# or asynchronous (return immediately)
389+
sync=sync
390+
)
391+
392+
352393
Explainable AI: Get Metadata
353394
----------------------------
354395

0 commit comments

Comments
0 (0)
You are visitor 01402792 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.