Skip to content

Commit ccd62d8

Browse files
committed
🚚 Rename checker
1 parent 380d0aa commit ccd62d8

File tree

3 files changed

+16
-16
lines changed

3 files changed

+16
-16
lines changed

include/checker/dd/HybridSchrodingerFeynmanChecker.hpp include/checker/dd/DDHybridSchrodingerFeynmanChecker.hpp

+5-5
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
namespace ec {
2424
/**
2525
* @brief Approximate Equivalence Checking with the
26-
* HybridSchrodingerFeynmanChecker This checker divides a circuit horizontally
26+
* DDHybridSchrodingerFeynmanChecker This checker divides a circuit horizontally
2727
* into two halves: a lower part and an upper part. This is achieved by
2828
* decomposing controlled gates, acting across both halves, according to the
2929
* Schmidt decomposition. By leveraging key trace equalities - specifically,
@@ -41,12 +41,12 @@ namespace ec {
4141
* @note Only suitable for shallow circuits with a maximum number of 63
4242
* controlled gates acting on both circuit parts (decisions).
4343
*/
44-
class HybridSchrodingerFeynmanChecker final
44+
class DDHybridSchrodingerFeynmanChecker final
4545
: public DDEquivalenceChecker<qc::MatrixDD, dd::DDPackageConfig> {
4646
public:
47-
HybridSchrodingerFeynmanChecker(const qc::QuantumComputation& circ1,
48-
const qc::QuantumComputation& circ2,
49-
ec::Configuration config)
47+
DDHybridSchrodingerFeynmanChecker(const qc::QuantumComputation& circ1,
48+
const qc::QuantumComputation& circ2,
49+
ec::Configuration config)
5050
: DDEquivalenceChecker(circ1, circ2, std::move(config)),
5151
qc1(std::make_unique<qc::QuantumComputation>(circ1)),
5252
qc2Inverted(std::make_unique<qc::QuantumComputation>()) {

src/EquivalenceCheckingManager.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -10,8 +10,8 @@
1010
#include "ThreadSafeQueue.hpp"
1111
#include "checker/dd/DDAlternatingChecker.hpp"
1212
#include "checker/dd/DDConstructionChecker.hpp"
13+
#include "checker/dd/DDHybridSchrodingerFeynmanChecker.hpp"
1314
#include "checker/dd/DDSimulationChecker.hpp"
14-
#include "checker/dd/HybridSchrodingerFeynmanChecker.hpp"
1515
#include "checker/dd/simulation/StateType.hpp"
1616
#include "checker/zx/ZXChecker.hpp"
1717
#include "circuit_optimizer/CircuitOptimizer.hpp"
@@ -535,7 +535,7 @@ void EquivalenceCheckingManager::checkSequential() {
535535
}
536536

537537
if (configuration.execution.runHSFChecker && !done) {
538-
checkers.emplace_back(std::make_unique<HybridSchrodingerFeynmanChecker>(
538+
checkers.emplace_back(std::make_unique<DDHybridSchrodingerFeynmanChecker>(
539539
qc1, qc2, configuration));
540540
const auto& hsfChecker = checkers.back();
541541
if (!done) {
@@ -691,7 +691,7 @@ void EquivalenceCheckingManager::checkParallel() {
691691
if (configuration.execution.runHSFChecker && !done) {
692692
// start a new thread that constructs and runs the HSF check
693693
futures.emplace_back(
694-
asyncRunChecker<HybridSchrodingerFeynmanChecker>(id, queue));
694+
asyncRunChecker<DDHybridSchrodingerFeynmanChecker>(id, queue));
695695
++id;
696696
}
697697

@@ -785,7 +785,7 @@ void EquivalenceCheckingManager::checkParallel() {
785785
// answers once they finish
786786
if ((dynamic_cast<const DDAlternatingChecker*>(checker) != nullptr) ||
787787
(dynamic_cast<const DDConstructionChecker*>(checker) != nullptr) ||
788-
(dynamic_cast<const HybridSchrodingerFeynmanChecker*>(checker) !=
788+
(dynamic_cast<const DDHybridSchrodingerFeynmanChecker*>(checker) !=
789789
nullptr)) {
790790
setAndSignalDone();
791791
results.equivalence = result;

src/checker/dd/HybridSchrodingerFeynmanChecker.cpp src/checker/dd/DDHybridSchrodingerFeynmanChecker.cpp

+7-7
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#include "checker/dd/HybridSchrodingerFeynmanChecker.hpp"
1+
#include "checker/dd/DDHybridSchrodingerFeynmanChecker.hpp"
22

33
#include "Definitions.hpp"
44
#include "EquivalenceCriterion.hpp"
@@ -28,7 +28,7 @@
2828
#include <thread>
2929

3030
namespace ec {
31-
std::size_t HybridSchrodingerFeynmanChecker::getNDecisions(
31+
std::size_t DDHybridSchrodingerFeynmanChecker::getNDecisions(
3232
qc::QuantumComputation& qc) const {
3333
std::size_t ndecisions = 0;
3434
// calculate number of decisions
@@ -86,7 +86,7 @@ std::size_t HybridSchrodingerFeynmanChecker::getNDecisions(
8686
return ndecisions;
8787
}
8888

89-
dd::ComplexValue HybridSchrodingerFeynmanChecker::simulateSlicing(
89+
dd::ComplexValue DDHybridSchrodingerFeynmanChecker::simulateSlicing(
9090
std::unique_ptr<DDPackage>& sliceDD1, std::unique_ptr<DDPackage>& sliceDD2,
9191
size_t i) {
9292
Slice lower(sliceDD1, 0, splitQubit - 1, i);
@@ -104,7 +104,7 @@ dd::ComplexValue HybridSchrodingerFeynmanChecker::simulateSlicing(
104104
return result;
105105
}
106106

107-
bool HybridSchrodingerFeynmanChecker::Slice::apply(
107+
bool DDHybridSchrodingerFeynmanChecker::Slice::apply(
108108
std::unique_ptr<DDPackage>& sliceDD,
109109
const std::unique_ptr<qc::Operation>& op) {
110110
bool isSplitOp = false;
@@ -174,15 +174,15 @@ bool HybridSchrodingerFeynmanChecker::Slice::apply(
174174
return isSplitOp;
175175
}
176176

177-
EquivalenceCriterion HybridSchrodingerFeynmanChecker::run() {
177+
EquivalenceCriterion DDHybridSchrodingerFeynmanChecker::run() {
178178
const auto start = std::chrono::steady_clock::now();
179179
equivalence = checkEquivalence();
180180
const auto end = std::chrono::steady_clock::now();
181181
runtime += std::chrono::duration<double>(end - start).count();
182182
return equivalence;
183183
}
184184

185-
EquivalenceCriterion HybridSchrodingerFeynmanChecker::checkEquivalence() {
185+
EquivalenceCriterion DDHybridSchrodingerFeynmanChecker::checkEquivalence() {
186186
const auto ndecisions = getNDecisions(*qc1) + getNDecisions(*qc2Inverted);
187187
if (ndecisions > 63) {
188188
throw std::overflow_error(
@@ -227,7 +227,7 @@ EquivalenceCriterion HybridSchrodingerFeynmanChecker::checkEquivalence() {
227227
return EquivalenceCriterion::NotEquivalent;
228228
}
229229

230-
void HybridSchrodingerFeynmanChecker::json(
230+
void DDHybridSchrodingerFeynmanChecker::json(
231231
nlohmann::basic_json<>& j) const noexcept {
232232
DDEquivalenceChecker::json(j);
233233
j["checker"] = "decision_diagram_hybridSchrodingerFeynman";

0 commit comments

Comments
 (0)