in google_cloud_automlops/orchestration/base.py [0:0]
def __init__(self,
func: Optional[Callable] = None,
name: Optional[str] = None,
description: Optional[str] = None,
comps_dict: dict = None):
"""Initiates a pipeline object created out of a function holding
all necessary code.
Args:
func (Optional[Callable]): The python function to create a pipeline from. The function
should have type annotations for all its arguments, indicating how it is intended to
be used (e.g. as an input/output Artifact object, a plain parameter, or a path to a
file). Defaults to None.
name (Optional[str]): The name of the pipeline. Defaults to None.
description (Optional[str]): Short description of what the pipeline does. Defaults to None.
comps_list (dict): Dictionary of potential components for pipeline to utilize imported
as the global held in AutoMLOps.py. Defaults to None.
"""
# Instantiate and set key pipeline attributes
self.func = func
self.func_name = func.__name__
self.name = DEFAULT_PIPELINE_NAME if not name else name
self.description = description
self.src_code = get_function_source_definition(self.func)
self.comps = self.get_pipeline_components(func, comps_dict)
# Instantiate attributes to be set at build process
self.base_image = None
self.custom_training_job_specs = None
self.pipeline_params = None
self.pubsub_topic_name = None
self.use_ci = None
self.project_id = None
self.gs_pipeline_job_spec_path = None
self.setup_model_monitoring = None