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

Add IR to Jet #11

Merged
merged 15 commits into from
May 25, 2021
Merged

Add IR to Jet #11

merged 15 commits into from
May 25, 2021

Conversation

thisac
Copy link

@thisac thisac commented May 20, 2021

Adds the IR to Jet, stored in python/ir. This folder contains the following:

  • The grammar, parser and program class.
  • A utilities file (used by parser/program)
  • A usage guide (same as grammar.md in the IR repo) describing the syntax of the IR.
  • The Strawberry Fields interface, consisting of a single file with a SF-to/from-IR-program converter function.
  • A tests folder containing tests for the IR.

To-do/To-discuss

  • Move tests to a better place (e.g., python/tests)
  • Rewrite usage_guide.md to fit better with Jet.
  • Add strawberryfields and lark to requirements.

@thisac thisac self-assigned this May 20, 2021
@github-actions
Copy link

github-actions bot commented May 20, 2021

Test Report (C++) on Ubuntu

    1 files  ±0      1 suites  ±0   0s ⏱️ ±0s
239 tests ±0  239 ✔️ ±0  0 💤 ±0  0 ❌ ±0 
519 runs  ±0  519 ✔️ ±0  0 💤 ±0  0 ❌ ±0 

Results for commit c62d635. ± Comparison against base commit c62d635.

♻️ This comment has been updated with latest results.

@thisac thisac changed the title Add IR to Jet [WIP] Add IR to Jet May 20, 2021
@github-actions
Copy link

github-actions bot commented May 20, 2021

Test Report (C++) on MacOS

    1 files  ±0      1 suites  ±0   0s ⏱️ ±0s
239 tests ±0  239 ✔️ ±0  0 💤 ±0  0 ❌ ±0 
519 runs  ±0  519 ✔️ ±0  0 💤 ±0  0 ❌ ±0 

Results for commit c62d635. ± Comparison against base commit c62d635.

♻️ This comment has been updated with latest results.

Copy link
Collaborator

@Mandrenkov Mandrenkov 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!

As a follow-up to our meeting, we should:

  1. Update the formatter to comply with the standards set by SF and PL. Use make format to run the formatter locally.
  2. Ensure the Python tests pass in the CI environment.
  3. Add the required dependencies to requirements.txt (or requirement_test.txt).
  4. (Future PR) Migrate the IR user guide to the "Using Jet" section of the documentation (docs/use).

Copy link
Collaborator

@Mandrenkov Mandrenkov left a comment

Choose a reason for hiding this comment

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

Oh, and don't forget to update the changelog before you merge!

@thisac thisac requested a review from Mandrenkov May 21, 2021 20:42
.github/CHANGELOG.md Outdated Show resolved Hide resolved
Copy link
Collaborator

@Mandrenkov Mandrenkov left a comment

Choose a reason for hiding this comment

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

Thanks for the changes, Theo! I only ask that you address Josh's comment before merging.

python/requirements_test.txt Outdated Show resolved Hide resolved
python/tests/xir/test_io.py Outdated Show resolved Hide resolved
python/tests/xir/test_io.py Outdated Show resolved Hide resolved
python/tests/xir/test_io.py Outdated Show resolved Hide resolved
python/tests/xir/test_io.py Outdated Show resolved Hide resolved
python/tests/xir/test_io.py Outdated Show resolved Hide resolved
Co-authored-by: Josh Izaac <josh146@gmail.com>
Co-authored-by: Mikhail Andrenkov <Mandrenkov@users.noreply.github.com>
@thisac thisac changed the title [WIP] Add IR to Jet Add IR to Jet May 25, 2021
@thisac thisac merged commit c62d635 into main May 25, 2021
@thisac thisac deleted the add-ir branch May 25, 2021 14:49
@Mandrenkov Mandrenkov mentioned this pull request May 25, 2021
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants