dwavesystems / dwave-system

An API for easily incorporating the D-Wave system as a sampler, either directly or through Leap's cloud-based hybrid samplers
https://docs.ocean.dwavesys.com/
Apache License 2.0
87 stars 62 forks source link

TilingComposite support for Advantage processor #431

Closed jackraymond closed 2 years ago

jackraymond commented 2 years ago

The TilingComposite has been modified to allow tiling of Chimera structured problems over Pegasus as well as Chimera solvers. This is an important use case for certain users, who wish to compare Chimera-structured (or chimera embeddable) problems between the DW2000Q and Advantage generation processors, at high sample density. Some minor fixes were also introduced for Chimera case, catching some pathological behaviours.

The DWaveMockSampler has been modified to support Pegasus as well as Chimera structured solver emulation.

These changes allow straightforward generalization for the case of Zephyr topologies. These changes do not resolve all known outstanding issues with TilingComposite e.g. https://github.com/dwavesystems/dwave-system/issues/295 . This supports tiling of Chimera problems over Advantage (Pegasus-structured) processors, further changes are required to support tiling of Pegasus problems over Advantage (or DW2000Q) processors.

codecov-commenter commented 2 years ago

Codecov Report

Merging #431 (d1e6399) into master (10acaa5) will decrease coverage by 3.25%. The diff coverage is 88.15%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #431      +/-   ##
==========================================
- Coverage   90.85%   87.60%   -3.26%     
==========================================
  Files          22       22              
  Lines        1455     1492      +37     
==========================================
- Hits         1322     1307      -15     
- Misses        133      185      +52     
Impacted Files Coverage Δ
dwave/system/composites/tiling.py 91.75% <88.00%> (-4.31%) :arrow_down:
dwave/system/testing.py 96.36% <88.46%> (-2.58%) :arrow_down:
dwave/system/samplers/leap_hybrid_sampler.py 61.72% <0.00%> (-13.88%) :arrow_down:
dwave/system/samplers/clique.py 77.35% <0.00%> (-5.04%) :arrow_down:
dwave/system/samplers/dwave_sampler.py 84.47% <0.00%> (-3.11%) :arrow_down:
dwave/system/composites/embedding.py 95.85% <0.00%> (-1.19%) :arrow_down:

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 10acaa5...d1e6399. Read the comment docs.

jackraymond commented 2 years ago

Testing both edge defects and node defects independently for the tiling composite (and other functions) is quite important so I added that functionality to MockDWaveSampler as well. Other changes on November 8th are superficial - mostly PEP8 stuff, and doesn't impact tiling composite other than an expansion of the tests run.

arcondello commented 2 years ago

@JoelPasvolsky, do you want to finish reviewing?