tfx.v1.components.ImportSchemaGen
Stay organized with collections
Save and categorize content based on your preferences.
A TFX ImportSchemaGen component to import a schema file into the pipeline.
Inherits From: BaseComponent
, BaseNode
tfx.v1.components.ImportSchemaGen(
schema_file: str
)
ImportSchemaGen is a specialized SchemaGen which imports a pre-defined schema
file into the pipeline.
In a typical TFX pipeline, users are expected to review the schemas generated
with SchemaGen
and store them in SCM or equivalent. Those schema files can
be brought back to pipelines using ImportSchemaGen.
Here is an example to use the ImportSchemaGen:
schema_gen = ImportSchemaGen(schema_file=schema_path)
Component outputs
contains:
See the SchemaGen guide
for more details.
ImportSchemaGen works almost similar to Importer
except following:
schema_file
should be the full file path instead of directory holding it.
schema_file
is copied to the output artifact. This is different from
Importer
that loads an "Artifact" by setting its URI to the given path.
Args |
schema_file
|
File path to the input schema file. This file will be copied
to the output artifact which is generated inside the pipeline root
directory.
|
Attributes |
outputs
|
Component's output channel dict.
|
Methods
with_node_execution_options
with_node_execution_options(
node_execution_options: utils.NodeExecutionOptions
) -> typing_extensions.Self
Class Variables |
POST_EXECUTABLE_SPEC
|
None
|
PRE_EXECUTABLE_SPEC
|
None
|
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2024-05-03 UTC.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2024-05-03 UTC."],[],[],null,["# tfx.v1.components.ImportSchemaGen\n\n\u003cbr /\u003e\n\nA TFX ImportSchemaGen component to import a schema file into the pipeline.\n\nInherits From: [`BaseComponent`](../../../tfx/v1/types/BaseComponent), [`BaseNode`](../../../tfx/v1/types/BaseNode) \n\n tfx.v1.components.ImportSchemaGen(\n schema_file: str\n )\n\nImportSchemaGen is a specialized SchemaGen which imports a pre-defined schema\nfile into the pipeline.\n\nIn a typical TFX pipeline, users are expected to review the schemas generated\nwith `SchemaGen` and store them in SCM or equivalent. Those schema files can\nbe brought back to pipelines using ImportSchemaGen.\n\nHere is an example to use the ImportSchemaGen: \n\n schema_gen = ImportSchemaGen(schema_file=schema_path)\n\nComponent `outputs` contains:\n\n- `schema`: Channel of type [`standard_artifacts.Schema`](../../../tfx/v1/types/standard_artifacts/Schema) for schema result.\n\nSee [the SchemaGen guide](https://www.tensorflow.org/tfx/guide/schemagen)\nfor more details.\n\nImportSchemaGen works almost similar to `Importer` except following:\n\n- `schema_file` should be the full file path instead of directory holding it.\n- `schema_file` is copied to the output artifact. This is different from `Importer` that loads an \"Artifact\" by setting its URI to the given path.\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Args ---- ||\n|---------------|--------------------------------------------------------------------------------------------------------------------------------------------|\n| `schema_file` | File path to the input schema file. This file will be copied to the output artifact which is generated inside the pipeline root directory. |\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Attributes ---------- ||\n|-----------|----------------------------------|\n| `outputs` | Component's output channel dict. |\n\n\u003cbr /\u003e\n\nMethods\n-------\n\n### `with_node_execution_options`\n\n with_node_execution_options(\n node_execution_options: utils.NodeExecutionOptions\n ) -\u003e typing_extensions.Self\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n\u003cbr /\u003e\n\n| Class Variables --------------- ||\n|----------------------|--------|\n| POST_EXECUTABLE_SPEC | `None` |\n| PRE_EXECUTABLE_SPEC | `None` |\n\n\u003cbr /\u003e"]]