Skip to content
This repository was archived by the owner on Aug 20, 2025. It is now read-only.

Conversation

zyang7
Copy link
Contributor

@zyang7 zyang7 commented Jun 20, 2023

  • Adds tests for the CopyExampleGen component.
  • Reorganizes CopyExampleGen component file to have multiple helper functions for easier testing.
  • Modifies tfx_addons/copy_example_gen/README.md for capitalization nits.

Checks:

  • Tests pass
  • Appropriate changes to README are included in PR

@github-actions
Copy link
Contributor

Thanks for the PR! 🚀

Instructions: Approve using /lgtm and mark for automatic merge by using /merge.

2. Should the dictionary of file inputs take a path to a folder? Globs? Lists of individual files?
3. Assuming file copying is done entirely separately, [importer.generate_output_dict](https://github.com/tensorflow/tfx/blob/f8ce19339568ae58519d4eecfdd73078f80f84a2/tfx/dsl/components/common/importer.py#L153) be used as is to register the artifacts, or does some separate code using [MLMD](https://www.tensorflow.org/tfx/guide/mlmd) in a different way need to be written


## Project Team
Alex Ho, alexanderho@google.com, @alxndrnh

Zi Yang, zya@google.com, @zyang7
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

README.md file changes lgtm

@alxndrnh
Copy link
Contributor

alxndrnh commented Jun 22, 2023

/lgtm Ran component in vertex test with downstream components StatisticsGen and Trainer. Pipeline works and CopyExampleGen() finishes in same amount of time (14 seconds) as original commit. Tests lgtm too.

@github-actions
Copy link
Contributor

Approval received from @alxndrnh! ✅

PR is approved. Missing merge command to auto-merge PR!

Copy link
Contributor

@rcrowe-google rcrowe-google left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@rcrowe-google
Copy link
Contributor

/lgtm
/merge

@casassg
Copy link
Member

casassg commented Jun 22, 2023

also @zyang7 can you add copy_example_gen to https://github.com/tensorflow/tfx-addons/blob/main/tfx_addons/version.py#L83 so that tests are run?

Btw we need a merge command by @alxndrnh for this to merge as the sole owner of the component

@zyang7
Copy link
Contributor Author

zyang7 commented Jun 22, 2023

@casassg Sure I can add it, I'm not sure what dependencies I need, is there a way to validate the versions to dependency mapping is correct?

@casassg
Copy link
Member

casassg commented Jun 22, 2023

@zyang7 given the imports in https://github.com/tensorflow/tfx-addons/blob/main/tfx_addons/copy_example_gen/component.py#L45 I think you just need tfx, so you can just add

"copy_example_gen": [f"tfx{_TFXVERSION_CONSTRAINT}"]

also you can just push here after adding this and it should trigger the tests (it will likely trigger them all given you are changing version.py so it may take a while) but once that runs you can see if its compatible or not. It runs a test w the lowest version of TFX we support and highest one which usually covers pretty good compatibility

@zyang7 zyang7 requested a review from hanneshapke as a code owner June 22, 2023 20:32
@github-actions github-actions bot added needs-lgtm and removed lgtm labels Jun 22, 2023
@zyang7
Copy link
Contributor Author

zyang7 commented Jun 22, 2023

Thanks @casassg! Addressed your comments.

@rcrowe-google
Copy link
Contributor

rcrowe-google commented Jun 22, 2023 via email

@alxndrnh
Copy link
Contributor

alxndrnh commented Jun 22, 2023

/lgtm /merge Thank you @casassg for the catch and helpful comments. If there's anything else please let us know. Additionally, thank you @zyang7 for the quick turnaround time with these changes.

@rcrowe-google I agree we need to add Zi as a codeowner.

@github-actions
Copy link
Contributor

Approval and merge request received from @alxndrnh! ✅

PR is missing approvals for some files still.

@casassg
Copy link
Member

casassg commented Jun 22, 2023

/lgtm /merge (as version.py owner)

@github-actions github-actions bot merged commit 4f728ab into tensorflow:main Jun 22, 2023
@github-actions
Copy link
Contributor

Merged with approvals from alxndrnh and casassg - thanks for the contribution! 🎉

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants