Closed thisac closed 3 years ago
Merging #611 (12b1f14) into master (ec08408) will increase coverage by
0.00%
. The diff coverage is98.59%
.
@@ Coverage Diff @@
## master #611 +/- ##
=======================================
Coverage 98.56% 98.56%
=======================================
Files 77 77
Lines 8893 8904 +11
=======================================
+ Hits 8765 8776 +11
Misses 128 128
Impacted Files | Coverage Δ | |
---|---|---|
strawberryfields/program.py | 100.00% <ø> (ø) |
|
strawberryfields/tdm/tdmprogram.py | 98.24% <98.38%> (+0.08%) |
:arrow_up: |
strawberryfields/api/devicespec.py | 95.31% <100.00%> (+0.07%) |
:arrow_up: |
strawberryfields/engine.py | 96.49% <100.00%> (ø) |
|
strawberryfields/io.py | 96.90% <100.00%> (ø) |
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update ec08408...12b1f14. Read the comment docs.
Ah, I see. Very clever, thanks!
On Thu., Jul. 22, 2021, 18:07 Theodor, @.***> wrote:
@.**** commented on this pull request.
In strawberryfields/tdm/tdmprogram.py https://github.com/XanaduAI/strawberryfields/pull/611#discussion_r674952351 :
- @property
- def concurr_modes(self):
- """The number of concurrent modes in the program."""
- return self._concurr_modes
This is just Pythons way of saying that self._concurr_modes is private (and shouldn't be changed manually outside of the class). By having a property, the value can be retrieved but not set (you'd need to add a "setter" method as well to do that, which could involve extra validation etc.).
— You are receiving this because your review was requested. Reply to this email directly, view it on GitHub https://github.com/XanaduAI/strawberryfields/pull/611#discussion_r674952351, or unsubscribe https://github.com/notifications/unsubscribe-auth/AO3BH2CSHCLKGEM6CBKHB2DTZA64JANCNFSM5AY23BIA .
-- xanadu.ai http://xanadu.ai
"To build quantum computers that are useful and available to people everywhere"
This e-mail message is privileged, confidential and subject to copyright. Any unauthorized use or disclosure is prohibited. Le contenu du présent courriel est privilégié, confidentiel et soumis à des droits d'auteur. Il est interdit de l'utiliser ou de le divulguer sans autorisation.
Ready for review, but since it relies on changes in the
td3-tdmprogram
branch, it's best to wait till that one is merged before merging this PR. Thus thedo not merge
label.Context: The TDMProgram will produce wrong results if the number of timebins is not an integer multiple of the number of concurrent modes. This is because the tdmprogram.unroll() function simpy multiplies the unique circuit with the number of shots, not taking into account which qumode has been measured most recently.
Description of the Change:
The way multiple shots are calculated is changed. It now calculates each shot separately instead of stitching together several identical circuits at the end.
The way the measured mode order is calculated is improved (and now works with the new shots calculation).
TDMProgram
is tidied up slightly by changing a few attributes to private and adding corresponding properties to access them.Benefits: The following now works properly:
outputting
Possible Drawbacks:
Related GitHub Issues: fixes #607