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

release back to pool on photon discard event #531

Merged
merged 4 commits into from
Oct 17, 2023

Conversation

res6idue
Copy link
Contributor

@res6idue res6idue commented Jul 17, 2023

This PR fixes the issue that the memory gets used up, resulting in a kill during some simulations


This change is Reviewable

@res6idue res6idue requested a review from zigen July 17, 2023 07:36
@zigen zigen requested a review from Naphann July 17, 2023 07:50
Copy link
Contributor

@Naphann Naphann left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 1 files reviewed, 1 unresolved discussion (waiting on @res6idue and @zigen)


quisp/modules/PhysicalConnection/BSA/BellStateAnalyzer.cc line 178 at r1 (raw file):

}

void BellStateAnalyzer::measureSuccessfully(PhotonRecord &p, PhotonRecord &q, bool is_psi_plus) {

If discard photon function doesn't return photonic qubits to pool properly. What about this one? Have you checked this case?

Copy link
Contributor Author

@res6idue res6idue left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 1 files reviewed, 1 unresolved discussion (waiting on @Naphann and @zigen)


quisp/modules/PhysicalConnection/BSA/BellStateAnalyzer.cc line 178 at r1 (raw file):

Previously, Naphann (Naphan Benchasattabuse) wrote…

If discard photon function doesn't return photonic qubits to pool properly. What about this one? Have you checked this case?

I think for the case when we hit this function, we still arrive at discard photons
Well I think that when we fail in the indistinguishable window, we also need to discard those photons, so I will fix it.

@res6idue res6idue requested a review from Chibikuri July 21, 2023 06:47
Copy link
Contributor Author

@res6idue res6idue left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 1 files reviewed, 1 unresolved discussion (waiting on @Chibikuri, @Naphann, and @zigen)


quisp/modules/PhysicalConnection/BSA/BellStateAnalyzer.cc line 178 at r1 (raw file):

Previously, res6idue (soon) wrote…

I think for the case when we hit this function, we still arrive at discard photons
Well I think that when we fail in the indistinguishable window, we also need to discard those photons, so I will fix it.

Fixed.

Copy link
Contributor

@Naphann Naphann left a comment

Choose a reason for hiding this comment

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

Reviewed all commit messages.
Reviewable status: 0 of 1 files reviewed, 2 unresolved discussions (waiting on @Chibikuri, @res6idue, and @zigen)


quisp/modules/PhysicalConnection/BSA/BellStateAnalyzer.cc line 178 at r1 (raw file):

Previously, res6idue (soon) wrote…

Fixed.

See my other comment.


quisp/modules/PhysicalConnection/BSA/BellStateAnalyzer.cc line 102 at r2 (raw file):

    auto q = second_port_records[i];

    if (fabs(p.arrival_time - q.arrival_time) < indistinguishability_window) {

What about this case? Do they get returned to the pool properly somewhere?

Copy link
Contributor Author

@res6idue res6idue left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 1 files reviewed, 2 unresolved discussions (waiting on @Chibikuri, @Naphann, and @zigen)


quisp/modules/PhysicalConnection/BSA/BellStateAnalyzer.cc line 102 at r2 (raw file):

Previously, Naphann (Naphan Benchasattabuse) wrote…

What about this case? Do they get returned to the pool properly somewhere?

sorry, I forgot to add the discard photon function for the successful case.

Copy link
Contributor Author

@res6idue res6idue left a comment

Choose a reason for hiding this comment

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

Reviewable status: 0 of 1 files reviewed, 2 unresolved discussions (waiting on @Chibikuri, @Naphann, and @zigen)


quisp/modules/PhysicalConnection/BSA/BellStateAnalyzer.cc line 102 at r2 (raw file):

Previously, res6idue (soon) wrote…

sorry, I forgot to add the discard photon function for the successful case.

Added.

Copy link
Contributor

@Naphann Naphann left a comment

Choose a reason for hiding this comment

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

Reviewed 1 of 1 files at r3, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @Chibikuri and @zigen)

Copy link
Contributor

@zigen zigen left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewed 2 of 2 files at r4, all commit messages.
Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @Chibikuri)

Copy link
Contributor

@Naphann Naphann left a comment

Choose a reason for hiding this comment

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

:lgtm:

Reviewable status: :shipit: complete! all files reviewed, all discussions resolved (waiting on @Chibikuri)

@res6idue res6idue removed the request for review from Chibikuri October 17, 2023 11:55
@res6idue res6idue merged commit 50bb7e7 into master Oct 17, 2023
16 of 18 checks passed
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