Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: Set default return type to ExportedProgram #2575

Merged
merged 12 commits into from
Feb 20, 2024
Merged

chore: Set default return type to ExportedProgram #2575

merged 12 commits into from
Feb 20, 2024

Conversation

peri044
Copy link
Collaborator

@peri044 peri044 commented Jan 5, 2024

Description

This change adds the following

  1. Returns ExportedProgram as the output of compilation by default
  2. output_format flag to return desired output format (exported_program | torchscript | graph_module)
  3. Modify export serde test cases to handle the above changes

Fixes # (issue)

Type of change

Please delete options that are not relevant and/or add your own.

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • This change requires a documentation update

Checklist:

  • My code follows the style guidelines of this project (You can use the linters)
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas and hacks
  • I have made corresponding changes to the documentation
  • I have added tests to verify my fix or my feature
  • New and existing unit tests pass locally with my changes
  • I have added the relevant labels to my PR in so that relevant reviewers are notified

@github-actions github-actions bot added component: api [Python] Issues re: Python API component: dynamo Issues relating to the `torch.compile` or `torch._dynamo.export` paths component: tests Issues re: Tests labels Jan 5, 2024
@github-actions github-actions bot requested a review from gs-olive January 5, 2024 02:09
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Code conforms to C++ style guidelines

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Code conforms to Python style guidelines

Copy link
Collaborator

@gs-olive gs-olive left a comment

Choose a reason for hiding this comment

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

Overall looks good. Added a question, and it seems 2 tests are failing currently. Consider redirecting the branch to the staging_rel_2_2 branch to get the release test suite.

py/torch_tensorrt/dynamo/_exporter.py Outdated Show resolved Hide resolved
Copy link
Collaborator

@narendasan narendasan left a comment

Choose a reason for hiding this comment

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

We need documentation updates in this PR

@peri044
Copy link
Collaborator Author

peri044 commented Jan 8, 2024

This PR has an open issue pytorch/pytorch#116831 which should be fixed first

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Code conforms to C++ style guidelines

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Code conforms to Python style guidelines

@github-actions github-actions bot added the documentation Improvements or additions to documentation label Jan 10, 2024
Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Code conforms to Python style guidelines

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Code conforms to C++ style guidelines

Copy link
Collaborator

@gs-olive gs-olive left a comment

Choose a reason for hiding this comment

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

Overall, looks great - just added a few questions on the exporter.

py/torch_tensorrt/dynamo/_exporter.py Outdated Show resolved Hide resolved
py/torch_tensorrt/dynamo/_exporter.py Outdated Show resolved Hide resolved
py/torch_tensorrt/dynamo/_exporter.py Show resolved Hide resolved
chore: Add output_format flag

chore: updates

chore: additional fixes

chore: add break
github-actions[bot]

This comment was marked as outdated.

@github-actions github-actions bot added component: lowering Issues re: The lowering / preprocessing passes component: conversion Issues re: Conversion stage labels Feb 1, 2024
@peri044 peri044 merged commit afd5abe into main Feb 20, 2024
28 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla signed component: api [Python] Issues re: Python API component: build system Issues re: Build system component: conversion Issues re: Conversion stage component: dynamo Issues relating to the `torch.compile` or `torch._dynamo.export` paths component: fx component: lowering Issues re: The lowering / preprocessing passes component: runtime component: tests Issues re: Tests documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants