# Full Quantum Process Tomography of a Universal Entangling Gate on an IBM’s
Quantum Computer

Muhammad AbuGhanem1,2,⋆ 1 Faculty of Science, Ain Shams University, Cairo,
11566, Egypt  2 Zewail City of Science, Technology and Innovation, Giza,
12678, Egypt<EMAIL_ADDRESS>
###### Abstract

Characterizing quantum dynamics is a cornerstone pursuit across quantum
physics, quantum information science, and quantum computation. The precision
of quantum gates in manipulating input basis states and their intricate
superpositions is paramount. In this study, we conduct a thorough analysis of
the SQSCZ gate, a universal two-qubit entangling gate, using real quantum
hardware. This gate is a fusion of the square root of SWAP ($\sqrt{SWAP}$) and
the square root of controlled-Z ($\sqrt{CZ}$) gates, serves as a foundational
element for constructing universal gates, including the controlled-NOT gate.
we begin by explaining the theory behind quantum process tomography (QPT),
exploring the Choi-Jamiolkowski isomorphism or the Choi matrix representation
of the quantum process, along with a QPT algorithm utilizing Choi
representation. Subsequently, we provide detailed insights into the
experimental realization of the SQSCZ gate using a transmon-based
superconducting qubit quantum computer. To comprehensively assess the gate’s
performance on a noisy intermediate-scale quantum (NISQ) computer, we conduct
QPT experiments across diverse environments, employing both IBM Quantum’s
simulators and IBM Quantum’s real quantum computer. Leveraging the Choi matrix
in our QPT experiments allows for a comprehensive characterization of our
quantum operations. Our analysis unveils commendable fidelities and noise
properties of the SQSCZ gate, with process fidelities reaching $97.27098\%$
and $88.99383\%$, respectively. These findings hold promising implications for
advancing both theoretical understanding and practical applications in the
realm of quantum computation.

Quantum process tomography, Process matrix, Choi-Jamiolokowski isomorphism,
Universal entangling gates, The SQSCZ gate, IBM Quantum computers
PACS: $03.67.Lx,\,03.67.-a$, $03.65.Ca$

††preprint: APS/123-QED

##  I Introduction

Quantum information science has sparked a revolution, birthing a plethora of
cutting-edge technologies and applications poised to redefine the future [1,
2]. Among these groundbreaking domains, quantum cryptography [3], quantum
computation [4], and quantum sensing [5] shine as beacons of innovation,
promising to usher in the next technological era [1, 3, 4, 5, 6, 7, 8, 9, 10].

However, the realization of complex quantum machines and networks hinges upon
a thorough understanding of their constituent components. Quantum process
tomography (QPT) emerges as a powerful tool in this pursuit, enabling the
meticulous reconstruction of component actions within quantum systems [11,
12].

QPT’s versatility is showcased in its application across diverse quantum
physical systems. From the realm of photonic qubits [13] and liquid-state NMR
[14, 15] to the intricacies of atoms in optical lattices [16] and trapped ions
[17], QPT has proven indispensable [14, 15, 13, 16, 17]. Even in cutting-edge
domains like continuous-variable quantum states [18], solid-state qubits [19],
semiconductor quantum dot qubits [20], and nonlinear optical systems [21],
with various practical implementations on NISQ computers [22, 23, 24]. QPT
continues to push the boundaries of characterization [19, 18, 20, 21].

Yet, the quest for comprehensive understanding extends beyond individual
components to encompass entire quantum communication channels. Within the
realms of quantum key distribution (QKD) and quantum communications [25, 26,
27], the characterization of quantum channels and components takes on
paramount importance [28, 29]. In this endeavor, quantum channels reveal
themselves as conduits of potential both for seamless communication and
clandestine interception. Categorized into optical fiber, line-of-sight free-
space, and ground-to-satellite links, these channels serve as lifelines in the
quantum realm [30, 31, 32].

Quantum process characterization, such as that of communication channels,
serves as a crucial component in the establishment of quantum information
systems. In quantum key distribution protocols, the level of noise present in
the channel directly impacts the rate at which confidential bits are exchanged
between authorized parties [33, 34]. Specifically, tomographic protocols
enable comprehensive reconstruction, thereby facilitating the thorough
characterization of the channel [35, 36, 37].

QPT constitutes a vital procedure aimed at validating quantum gates and
identifying shortcomings in configurations and gate designs. The primary
objective of QPT is to extract a comprehensive description of the dynamical
map (quantum process) based on a series of well-designed experiments. In this
paper, we perform QPT experiments utilizing the Choi matrix representation of
quantum processes [38, 39], in order to provide a complete characterization of
the SQSCZ gate’s performance on NISQ computers, the QPT analysis conducted
across diverse environments, employing both IBM Quantum’s simulators
(qasm_simulator) and a real quantum computer (ibm_perth) [40].

The subsequent sections of this paper are organized as follows: Section II
provides a succinct outline of the principles underlying quantum process
tomography (QPT), emphasizing the Choi-Jamiolkowski isomorphism or the Choi
matrix representation of quantum processes, along with a QPT algorithm
employing Choi representation. Following this theoretical foundation, Section
III presents a concise overview of the two-qubit entangling gate, SQSCZ. In
Section IV, we delve into the experimental implementation of the SQSCZ gate
utilizing a transmon-based superconducting qubit quantum computer. Building
upon this experimental setup, Section V encompasses our efforts to
comprehensively assess the gate’s performance on a NISQ computer through QPT
experiments conducted across diverse environments, employing both IBM
Quantum’s simulators and real quantum computers. These QPT experiments
utilized the Choi matrix to achieve a comprehensive characterization of our
quantum operations. In Section VI, we undertake tests and analyses to
scrutinize gate fidelities and noise properties of the SQSCZ gate, paving the
way for our ensuing discussion. Finally, we draw our conclusions in Section
VII.

##  II Quantum Process Tomography

###  II.1 Theory of QPT

QPT aims to extract a complete description of a dynamical map ${\cal E}$ based
on a series of well-designed experiments [12]. Standard QPT involves
initializing system qubits in a suitable density matrix basis, subjecting
these basis states to a specific process, and subsequently characterizing the
resulting quantum states using a quantum state tomography algorithm [24]. In
this process, a density matrix ${\cal P}_{\text{in}}$ undergoes a linear
transformation into another density matrix ${\cal P}_{\text{out}}$ by
traversing through a general quantum operation ${\cal E}$, such that ${\cal
P}_{\text{out}}={\cal E}({\cal P}_{\text{in}})$. Here, ${\cal P}_{\text{in}}$
and ${\cal P}_{\text{out}}$ represent the input and output density matrices,
respectively. The transformation ${\cal E}:{\cal
P}_{\text{in}}\longrightarrow{\cal P}_{\text{out}}$ is fully characterized by
a positive Hermitian matrix $\chi$, such that:

${\cal P}_{\text{out}}\equiv{\cal E}({\cal
P}_{\text{in}})=\sum_{m,n}\chi_{mn}\widehat{W}_{m}{\cal
P}_{\text{in}}{\widehat{W}}^{{\dagger}}_{n},$ (1)

Here, ${\cal E}$ represents a completely positive quantum dynamical map, which
illustrates the system’s behavior on any d-dimensional input state ${\cal
P}_{\text{in}}$. This map is commonly known as a quantum process. The trace-
preserving positive Hermitian matrix $\chi_{mn}$, with dimensions $d^{2}\times
d^{2}$, known as the “process matrix,” fully and distinctly characterizes the
operation of the process ${\cal E}$. In this context, the operators
$\widehat{W}_{m}$ constitute a complete basis, usually represented by the
Pauli operators or, in higher dimensions, the Gell-Mann operators. Also, the
dimensions of the $\widehat{W}_{m}$ matrices match those of density operators.
It’s noteworthy that the dimensions of the $\widehat{W}_{m}$ matrices match
those of density operators. For instance, in scenarios involving $K$ qubits,
where $d=2^{K}$, there exist $4^{K}$ operators $\widehat{W}_{n}$, resulting in
a process matrix dimension of $4^{K}\times 4^{K}$.

Various mathematical representations exist for a completely positive (${\cal
E}\otimes\mathbb{I}\geq zero$) and trace-preserving ($\rm{tr}({\cal E}({\cal
P}))=\rm{tr}({\cal P})$) (CPTP) map [4, 43], including Choi representation
[38, 39], the Kraus representation [41], and Pauli-Transfer-Matrix (PTM)
representation [42]. For a summary of these representations, please refer to
reference [43]. A standalone version of QPT, which does not necessitate
quantum state tomography (QST), is outlined in [44]. The process of QPT for a
high-dimensional quantum communication channel is elucidated in [37]. The
methodology of QPT employing completely positive and trace-preserving
projection is examined in [45]. QPT employing unsupervised learning and tensor
networks is demonstrated in [46]. For a comprehensive understanding of QPT
theory, detailed descriptions are available in [41, 11, 12, 47, 13]. In our
QPT experiments, we employed the Choi-Jamiolkowski isomorphism [38, 39], also
known as the Choi matrix, to achieve a comprehensive characterization of our
quantum operations. This approach allowed us to effectively represent and
analyze the behavior of our quantum processes.

###  II.2 The Choi representation

An alternative and convenient conceptualization of procedures is presented
through the Choi-Jamiolokowski isomorphism [38, 39], asserting that any
entirely positive mapping can be elucidated as an operator situated within a
$d^{2}$-dimensional Hilbert space ${\cal H}_{\mathrm{in}}\otimes{\cal
H}_{\mathrm{out}}$. This operator, denoted as the Choi matrix ${\cal C}_{\cal
E}$, is constructed as the outcome of the channel’s operation on one component
of a maximally entangled state.

Therefore, a quantum channel ${\cal E}$ can be fully characterized by a unique
bipartite matrix known as the Choi matrix ${\cal C}_{\cal
E}\in\mathscr{L}({\cal H}_{\mathrm{in}}\otimes{\cal H}_{\mathrm{out}})$, which
is derived from the Choi-Jamiolkowski isomorphism [38, 39]. Now, if the set of
kets
$\left\\{\left|{0}\right\rangle,\left|{1}\right\rangle,\dots,\left|{j-2}\right\rangle,\left|{j-1}\right\rangle\right\\}$
forms an orthonormal set of basis of both the input ${\cal H}_{\mathrm{in}}$
and the output ${\cal H}_{\mathrm{out}}$ Hilbert spaces, then the Choi
operator (matrix) ${\cal C}_{\cal E}$ is defined as follows:

${\cal C}_{\cal
E}=\sum_{k,m=0}^{j-1}\left|{k}\right\rangle\left\langle{m}\right|\otimes{\cal
E}\left(\left|{k}\right\rangle\left\langle{m}\right|\right).$ (2)

Using this Choi matrix representation, the evolution of a given quantum state
${\cal P}_{\text{in}}$ can be described by:

${\cal E}({\cal P}_{\text{in}})=\textrm{Tr}^{\pounds}_{{\cal
H}_{in}}\left[({\cal P}_{\text{in}}^{T}\otimes\mathbb{I})\,{\cal C}_{\cal
E}\right],$ (3)

here, the symbol $\textrm{Tr}^{\pounds}$ represents the partial trace over the
input state’s Hilbert space, with $\mathbb{I}$ defined as the (d-dimensional)
identity operator, and $T$ signifies the matrix transposition.

When preparing the quantum system in an initial state ${\cal P}_{k}$ and
subsequently performing a measurement, the probability of obtaining the
measurement outcome ($km$) for a projector $\Xi$ can be written as

$p_{km}=\textrm{Tr}\left[({\cal P}_{k}^{T}\otimes\Xi_{m})\,{\cal C}_{\cal
E}\right]$ (4)

The expression provided in Eq. (4) reveals that measuring the outcome of the
quantum channel ${\cal E}$ acting on an initial state ${\cal P}_{k}$ using a
projector $\Xi$ is similar to measuring the Choi matrix (${\cal C}_{\cal E}$)
as a quantum state within the space $\mathscr{L}({\cal
H}_{\mathrm{in}}\otimes{\cal H}_{\mathrm{out}})$ with a measurement operator
$({\cal P}^{T}\otimes\Xi)$.

In contrast to the Kraus representation [41], the Choi matrix associated with
a quantum channel possesses uniqueness. Consequently, QPT essentially entails
adjusting the matrix elements of ${\cal C}_{\cal E}$ to align with the data.
The data set comprises a distinct collection of prepared input states
introduced to the channel and a corresponding set of measurements on the
resulting output states. Specifically, a collection of input states and
measurements attains the status of being informationally-complete if the
inputs and the measurement operators collectively span the entire input and
output Hilbert spaces of the quantum channel, respectively.

###  II.3 QPT algorithm with the Choi representation

The conventional methodology for conducting QPT entails parameterizing the
Choi matrix, typically represented by a $4^{K}\times 4^{K}$ matrix, and
deducing its constituents through the resolution of the maximum likelihood
estimation problem [48]. This approach encounters two primary constraints.
Firstly, it necessitates the parameterization of the entire Choi matrix, a
task that escalates exponentially in complexity with the increase in the
number of qubits. Secondly, to attain a high-fidelity alignment, the
exhaustive informationally-complete set (ICS) of input states and measurements
is indispensable, a requirement that also grows exponentially with $K$.
Consequently, the practice of full QPT has remained confined to exceedingly
diminutive system dimensions. To date, owing to these constraints, QPT has
been applied experimentally to a maximum of 3 qubits [13, 17, 49, 50, 51, 52,
53, 54, 23, 24, 22, 55].

To conduct quantum process tomography (QPT) experiments using the Choi matrix,
the following steps are followed:

  * •

Step 1: Prepare a set of initial states, $\\{{\cal P}_{1},{\cal
P}_{2},\dots,{\cal P}_{s}\\}$.

  * •

Step 2: Construct a set of projectors $\\{P_{1},P_{2},\dots,P_{t}\\}$ such
that, for the state space $\mathscr{L}({\cal H}_{\mathrm{in}}\otimes{\cal
H}_{\mathrm{out}})$, the set of all projectors $\Xi_{i,j}=({\cal
P}^{T}_{i}\otimes P_{j})$ forms a tomographically complete set.

  * •

Step 3: Initialize the system to ${\cal P}_{i}$. Utilize a quantum computer or
a qasm simulator to apply the channel ${\cal E}$ and measure with $P_{j}$.

  * •

Step 4: Acquire measurements of ${\cal C}_{\cal E}$ with $\Xi_{ij}$.

  * •

Step 5: Pass the experimental results and the specification of $\Xi$ through a
QST algorithm.

  * •

Step 6: Utilize the measurement outcomes to construct the Choi matrix ${\cal
C}_{\cal E}$.

##  III An Overview of the SQSCZ Gate

Figure 1: A quantum circuit representation illustrating the de-construction of the SQSCZ gate into individual single-qubit operations and CNOT operations. The deconstruction of the SQSCZ gate involves a combination of single-qubit operations, namely rotation gates denoted as $\mathrm{R_{Z}}(.)$, and the square root of the NOT gate ($\mathrm{\sqrt{X}}$), along with the utilization of only two controlled-NOT (CNOT) gates. Figure 2: A quantum circuit that serves as an alternative to the controlled-NOT (CNOT) gate is devised, leveraging the SQSCZ gate. This CNOT gate configuration entails the integration of solely two SQSCZ gates, supplemented by a sequence of single-qubit gates. These single-qubit operations encompass the $X$ gate, rotation gates ($\mathrm{R}_{X},\mathrm{R}_{Z}$), and phase gates ($\mathrm{Ph}$). Figure 3:  The error map of the IBM Quantum machine ”ibm_perth” and its corresponding layout. This processor, identified as the Falcon r5.11H version 1.2.8, comprises seven superconducting transmon qubits, boasting a quantum volume (QV) of 32. The basis gates available on this quantum computer include CNOT, ID, RZ, SX, and X gates. Specific error metrics of this quantum computer, revealing a median CNOT error of $8.690\times 10^{-3}$, a median SX error of $2.860\times 10^{-4}$, and a median readout error of $2.930\times 10^{-2}$. Additionally, the median values for the coherence times T1 and T2 were found to be $168.65$ microseconds ($\mu$s) and $132.51$ microseconds ($\mu$s), respectively. Furthermore, the processor is capable of executing up to 100 quantum circuits, with a maximum of $20,000$ shots per circuit. Figure 4:  An analogous quantum circuit representing the SQSCZ two-qubit entangling gate is presented. The gate is deconstructed utilizing single-qubit gates, employing merely two Controlled-NOT (CNOT) operations. The execution of this quantum circuit is repated for 7,168 shots on the seven-qubit IBM quantum computer, named ibm_perth. Figure 5: The measurement outcomes stemming from the practical implementation of the two-qubit SQSCZ gate were meticulously analyzed. These results were derived following the execution of the experiment with $7,168$ shots, both on a qasm simulator and a real quantum computer, specifically the IBM Quantum device known as ”ibm_perth”. The presence of small probabilities in the outcomes can be attributed to noise inherent in quantum computation. The provided data represents the frequencies obtained for each of the two-qubit basis states. Table 1: The general operational efficacy of the seven-qubit IBM’s Quantum superconducting quantum computer, known as ibm_perth. Key parameters considered include coherence times $T1$ and $T2$, qubit frequency ($\omega/2\pi$), anharmonicity ($\gamma/2\pi$), readout length ($\delta$), readout assignment error ($\xi$), as well as the probabilities of bit flip ($\zeta$ and $\eta$), alongside single-qubit Pauli X/(SX) error. These metrics were accessed on September 23, 2023. $qubit~{}[i]$ | $T1(\mu s)$ | $T2(\mu s)$ | $\omega/2\pi\textrm{(GHz)}$ | $\gamma/2\pi\textrm{(GHz)}$ | $\xi(R)$ | $\zeta(\%)$ | $\eta(\%)$ |  $\delta$(ns) | Pauli X/(SX) error
---|---|---|---|---|---|---|---|---|---
$qubit~{}[0]$ | 112.21714928 | 89.95798047 | 5.15755952 | -0.341524517 | 0.0281 | 0.0292 | 0.027 | 721.7777778 | 0.00100025
$qubit~{}[1]$ | 143.97956535 | 54.15814934 | 5.03354584 | -0.344368702 | 0.0304 | 0.032 | 0.0288 | 721.7777778 | 0.00028598
$qubit~{}[2]$ | 214.03073768 | 95.99622158 | 4.86265682 | -0.347272472 | 0.0338 | 0.0272 | 0.0404 | 721.7777778 | 0.00026989
$qubit~{}[3]$ | 168.64915374 | 227.9672909 | 5.12510400 | -0.340441899 | 0.0161 | 0.0186 | 0.0136 | 721.7777778 | 0.00024909
$qubit~{}[4]$ | 169.53935454 | 132.5137580 | 5.15920959 | -0.333366537 | 0.0293 | 0.0286 | 0.03 | 721.7777778 | 0.00030961
$qubit~{}[5]$ | 148.76564849 | 142.0891481 | 4.97860983 | -0.346022031 | 0.03 | 0.0344 | 0.0256 | 721.7777778 | 0.00034369
$qubit~{}[6]$ | 188.84148933 | 231.3818681 | 5.15663665 | -0.340454390 | 0.0114 | 0.0126 | 0.0102 | 721.7777778 | 0.00026888
Table 2:  The error rates of controlled-NOT gates between distinct qubits ($qubit~{}[i]$) while operating on the ”$ibm\\_perth$” quantum computer, as accessed on September 23, 2023. $qubit$[index] | The coupling map | Error rates
---|---|---
$qubit~{}[0]$ | CX: $qubit~{}[0]-qubit~{}[1]$ | 0.00514
$qubit~{}[1]$ | CX: $qubit~{}[1]-qubit~{}[2]$ | 0.01136
CX: $qubit~{}[1]-qubit~{}[3]$ | 0.00499
CX: $qubit~{}[1]-qubit~{}[0]$ | 0.00514
$qubit~{}[2]$ | CX: $qubit~{}[2]-qubit~{}[1]$ | 0.01136
$qubit~{}[3]$ | CX: $qubit~{}[3]-qubit~{}[1]$ | 0.00499
CX: $qubit~{}[3]-qubit~{}[5]$ | 0.00723
$qubit~{}[4]$ | CX: $qubit~{}[4]-qubit~{}[5]$ | 0.01226
$qubit~{}[5]$ | CX: $qubit~{}[5]-qubit~{}[4]$ | 0.01226
CX: $qubit~{}[5]-qubit~{}[3]$ | 0.00723
CX: $qubit~{}[5]-qubit~{}[6]$ | 0.01367
$qubit~{}[6]$ | CX: $qubit~{}[6]-qubit~{}[5]$ | 0.01367

A paradigm shift toward quantum computing [56, 4, 57, 59, 58] promises
substantial practical implications, offering transformative potential for
computational methodologies, programming techniques, and complexity paradigms
[1, 6, 7, 8, 9, 10]. However, the realization of a functional quantum computer
critically hinges upon satisfying specific criteria, meticulously outlined by
DiVincenzo [56]. Among these criteria, a pivotal challenge lies in the
physical realization of quantum gates operating between qubits [58, 60, 61,
62, 63].

Universal quantum gates play an indispensable role in expediting efficient
algorithm execution on quantum computers, providing both rapid and fault-
tolerant manipulations. Serving as foundational components, these gates are
necessary for encoding intricate algorithms and operations within the large-
scale quantum computing systems [64].

The pursuit of high-fidelity two-qubit gates poses a formidable challenge,
particularly in experimental settings encompassing diverse quantum systems. In
the quest for a universal quantum computerr [1, 59, 4], a fundamental suite of
quantum gates, including two-qubit entangling gates [60, 65, 22, 55], is
essential. The effective integration of these gates signifies a crucial
milestone in the progression toward practical quantum computing systems [66].
In this regard, a scheme has been introduced [67, 68] to realize a novel two-
qubit entangling gate within Josephson junctions superconducting qubits in
[69]. This gate, known as SQSCZ, transforms the basis states as follows:

$\displaystyle\left|{0}\right\rangle_{A}\otimes\left|{0}\right\rangle_{B}\rightarrow\left|{0}\right\rangle_{A}\otimes\left|{0}\right\rangle_{B},$
(5)
$\displaystyle\left|{0}\right\rangle_{A}\otimes\left|{1}\right\rangle_{B}\rightarrow\frac{1}{2}(1+i)\left|{0}\right\rangle_{A}\otimes\left|{1}\right\rangle_{B}+\frac{1}{2}(1-i)\left|{1}\right\rangle_{A}\otimes\left|{0}\right\rangle_{B},$
$\displaystyle\left|{1}\right\rangle_{A}\otimes\left|{0}\right\rangle_{B}\rightarrow\frac{1}{2}(1-i)\left|{0}\right\rangle_{A}\otimes\left|{1}\right\rangle_{B}+\frac{1}{2}(1+i)\left|{1}\right\rangle_{A}\otimes\left|{0}\right\rangle_{B},$
$\displaystyle\left|{1}\right\rangle_{A}\otimes\left|{1}\right\rangle_{B}\rightarrow
i\left|{1}\right\rangle_{A}\otimes\left|{1}\right\rangle_{B}$

Here, the representation is in the 2-qubit basis
$\left\\{\left|{0}\right\rangle_{A}\otimes\left|{0}\right\rangle_{B},\,\left|{0}\right\rangle_{A}\otimes\left|{1}\right\rangle_{B},\,\left|{1}\right\rangle_{A}\otimes\left|{0}\right\rangle_{B},\,\left|{1}\right\rangle_{A}\otimes\left|{1}\right\rangle_{B}\right\\}$,
and the subscript $A$ signifies qubit A. The matrix operator corresponding to
SQSCZ reads,

$\displaystyle\hat{U}^{SQSCZ}$ $\displaystyle=\begin{pmatrix}1&0&0&0\\\
0&\frac{1}{2}(1+i)&\frac{1}{2}(1-i)&0\\\
0&\frac{1}{2}(1-i)&\frac{1}{2}(1+i)&0\\\ 0&0&0&i\end{pmatrix}$ (6)

The SQSCZ-gate is a fusion of the $\sqrt{SWAP}$-gate and the $\sqrt{CZ}$-gate,
which can be presented in the form
$\hat{U}^{\sqrt{SWAP}}\quad\hat{U}^{\sqrt{CZ}}=\hat{U}^{\sqrt{CZ}}\quad\hat{U}^{\sqrt{SWAP}}$,
where

$\hat{U}^{\sqrt{SWAP}}=\begin{pmatrix}1&0&0&0\\\
0&\frac{1}{2}(1+i)&\frac{1}{2}(1-i)&0\\\
0&\frac{1}{2}(1-i)&\frac{1}{2}(1+i)&0\\\ 0&0&0&1\end{pmatrix}$ (7)

and

$\hat{U}^{\sqrt{CZ}}=\begin{pmatrix}1&0&0&0\\\ 0&1&0&0\\\ 0&0&1&0\\\
0&0&0&i\end{pmatrix}$ (8)

are the $\sqrt{SWAP}$ and $\sqrt{CZ}$ gates expressed within the identical
basis as Eq. (6).

A quantum circuit representing the SQSCZ gate is depicted in Figure 1. This
schematic illustrates a circuit decomposition that offers an alternative
formulation of the SQSCZ two-qubit gate in terms of CNOTs gates. This
decomposition strategy employs a combination of single-qubit operations,
specifically rotation gates denoted as $\mathrm{R_{Z}}$, along with the square
root of NOT gate ($\mathrm{\sqrt{X}}$), facilitated by the inclusion of only
two controlled-NOT (CNOT) gates. Furthermore, the universal controlled-NOT
gate (CNOT) can be synthesized from the SQSCZ gate and single-qubit rotations
through various combinations. One such combination can be expressed as:
$[R_{X}(-\pi/2)Ph(\pi)\otimes R_{Z}(-\pi/2)]\quad\hat{U}^{SQSCZ}\quad[I\otimes
Ph(\pi/2)\,X]\quad\hat{U}^{SQSCZ}\quad[XH\otimes R_{X}(\pi/2)]$. Here, the
rotations are conducted with angles specified in radians. A quantum circuit
equivalent to the controlled-not (CNOT) gate, formulated in terms of the SQSCZ
gate, is introduced in Figure 2.

##  IV The Practical Implementation of the SQSCZ Gate

In this study, for the experimental implementation of our two-qubit quantum
gate, we utilized the IBM Quantum’s quantum computer known as ibm_perth. At
the core of this quantum computing machine lies a quantum processor of type
Falcon r5.11H version 1.2.8, featuring seven superconducting transmon qubits
arranged according to the configuration depicted in Figure 3. The available
basis gates on this quantum machine include CNOT, ID, RZ, SX, and X gates.
Noteworthy error metrics for this quantum computer include a median CNOT error
of $8.690\times 10^{-3}$, a median SX error of $2.860\times 10^{-4}$, and a
median readout error of $2.930\times 10^{-2}$. Additionally, median values for
the coherence times T1 and T2 were determined to be $168.65$ microseconds
($\mu$s) and $132.51$ microseconds ($\mu$s), respectively. Furthermore, the
processor boasts the capability to execute up to 100 quantum circuits, with a
maximum of $20,000$ shots per circuit. The general system characteristics and
qubit properties of the ibm_perth quantum computer are listed in Tabel 1,
whereas, the error rates of controlled-NOT gates between distinct qubits is
presented in Tabel 2.

The quantum circuit representing the SQSCZ gate is executed for $7,186$ shots
on both the qasm_simulator and the ibm_perth quantum computer, see Figure 4.
The qasm_simulator is designed to emulate quantum circuits under various
conditions, including both pristine and noisy environments. It supports a
range of simulation methodologies, each adaptable to meet the specific needs
of circuits and noise models. While the qasm_simulator replicates an ideal
quantum computing setting, it also provides the capability to mimic the
characteristics of real-world noisy quantum computers. For more in-depth
information on IBM Quantum’s simulators, readers are referred to [40].

The results of the measurements indicate that: On the qasm_simulator, out of
the $7,186$ shots, the classical register returns the state
$\left|{00}\right\rangle$ for the entirety of the measurements, while yielding
zero occurrences for the computational basis states $\left|{01}\right\rangle$,
$\left|{10}\right\rangle$, and $\left|{11}\right\rangle$. Conversely, in the
experimental implementation on the ibm_perth quantum computer, the measurement
outcomes are as follows: $\left|{00}\right\rangle$ is obtained in $6,680$
instances, $\left|{01}\right\rangle$ in $232$ instances,
$\left|{10}\right\rangle$ in $236$ instances, and $\left|{11}\right\rangle$ in
$20$ instances. The measurement outcomes from the actual execution of the two-
qubit gate on both the qasm_simulator and the quantum computer are illustrated
in Figure 5. Qubit properties and system performance during this experimental
implementations are presented in Tabel 4.

##  V The QPT Experiments

Figure 6:  The real ($\mathrm{Re}({\cal C}_{\cal E})$) and imaginary
($\mathrm{Im}({\cal C}_{\cal E})$) components of the Choi matrices,
reconstructed the QPT experiments for the two-qubit SQSCZ gate, are depicted
alongside the final results for the measurement outcomes across all circuits.
(a) Represents the ideal Choi matrix (theoretical expectations). (b)
Illustrates the results of QPT experiments conducted on an IBM Quantum
simulator (qasm_simulator). (c) Depicts the outcomes of QPT experiments
carried out on a real IBM quantum computer, ibm_perth. The QPT experiments
were repeated 11,000 times on the IBM Quantum’s qasm_simulator and for $4,000$
times in IBM’s Quantum compter ibm_perth, yielding process fidelities ${\cal
F_{P}}$ of $97.27098\%$ and $88.9938\%$, respectively. The total runtime on
the ibm_perth machine amounted to 2 minutes and 40 seconds.

Figure 7:  Quantum process tomography (QPT) of the two-qubit SQSCZ gate is
conducted on the sixteen two-qubit basis states in the Pauli basis:
$II,IX,IY,IZ,XI,XX,XY,XZ,YI,YX,YY,YZ,ZI,ZX,ZY$, and $ZZ$, visualized as Hinton
diagrams. (a) Illustrates visualizations of the ideal process matrix of the
two-qubit SQSCZ gate, devoid of effects arising from decoherence. (b) Depicts
the results of two-qubit process tomography for the SQSCZ gate executed on an
IBM Quantum simulator (qasm_simulator) with 11,000 shots. (c) Displays QPT
experiments performed for 4,000 shots on a real IBM quantum computer,
ibm_perth. The left panel illustrates the combined parts, while the middle and
right plots show the real and imaginary components, respectively. We
demonstrate process fidelities of $97.27098\%$ and $88.9938\%$ on the IBM
Quantum simulator and the IBM quantum computer ibm_perth, respectively.

Figure 8:  Performance metrics, distribution of parameters, and readout error
analysis for individual qubits on the IBM’s quantum processor ibm_perth during
the execution of the two-qubit SQSCZ quantum circuit and quantum process
tomography experiments pertaining to the SQSCZ gate. (a) T1 (microseconds),
(b) T2 (microseconds), (c) Qubit Frequency (gigahertz), (e) Readout assignment
error, (f) Probability of measuring $\left|{0}\right\rangle$ when preparing
$\left|{1}\right\rangle$, and (g) probability of measuring
$\left|{1}\right\rangle$ when preparing $\left|{10}\right\rangle$. (d) Qubit
Anharmonicity (gigahertz), (h)and Readout length (nanoseconds). SX gate error.

In this section, to comprehensively characterize our quantum gate and identify
potential flaws in configuration and gate design, we perform QPT experiments
for the SQSCZ gate. These quantum experiments are conducted using both the IBM
Quantum simulator, specifically the qasm_simulator, and an actual IBM quantum
computer, specifically the ibm_perth.

The QPT experiments were executed for $11,000$ shots using the qasm_simulator
and with $4,000$ repetitions on the real quantum computer ibm_perth. The
outcomes were utilized to construct the Choi matrices for the SQSCZ gate. By
computing the process fidelity ($0\leq{\cal F_{P}}\leq 1$) of noisy quantum
channels [70], a quantitative comparison was performed to assess the proximity
of the measured Choi matrices to the theoretical expectations (ideal process).
Figure 6 illustrates the real and imaginary components of the Choi matrices,
along with the corresponding process fidelities derived from the QPT
experimental implementations in the two environments. Additionally, for a more
detailed analysis of these QPT results, a Hinton diagram depicting the Choi
matrices is presented in Figure 7.

##  VI Analysis and Discussions

Quantum computation applications frequently require the utilization of quantum
fidelities to assess performance. Quantum fidelity plays a pivotal role in
quantifying the similarity between two quantum states. Numerous approaches
have been suggested for defining fidelity, typically involving a comparison
between the executed gate and the true channel operation. This channel
operation can be characterized by the Choi matrix [38, 39].

Table 4 presents detailed device specifications of the ibm_perth and the qubit
parameters utilized during the QPT experiments. The average coherence times
$T1$ and $T2$ are recorded as $118.76681\mu$s and $131.92139\mu$s,
respectively. The average qubit frequency ($\omega/2\pi$) is measured at
$5.0676159$ GHz, while the average qubit anharmonicity ($\gamma/2\pi$) is
determined to be $-0.3419215$ GHz. Additionally, the average qubit readout
assignment error ($\xi(R)$) is calculated to be $0.02419$. The qubit flip
probabilities ($\zeta$) and ($\eta$) exhibit averages of $0.0277333$ and
$0.0247666$, respectively. The average readout length ($\delta$) is determined
to be $721.77777$ ns. Figure 8 provides a visualization of the distribution of
parameters and readout errors for each qubit across the ibm_perth quantum
computer, along with the processor performance during the execution of the QPT
experiments.

As previously indicated, QPT represents a valuable methodology offering
insights into the manner in which a physical process alters states [12, 50].
It furnishes detailed insights into the inherent fallibility of processes and
the impact of noise or other imperfections on gate operations. Furthermore,
QPT serves a crucial function in the validation of quantum gates and the
identification of potential shortcomings in their configuration and design[23,
24].

The outcomes obtained from the repetition of the quantum experiment for
$4,000$ shots for each measurement basis on the ibm_perth, encompassing all
the QPT circuits executed for the two-qubit SQSCZ gate, are utilized to
reconstruct the Choi matrices. These matrices are depicted in Figures 6. In
Figure 6, we present the process matrices illustrating the characteristics of
the SQSCZ two-qubit gate in the Pauli basis. Including the theoretically
anticipated Choi matrix for the ideal SQSCZ gate, devoid of decoherence
effects, with the reconstructed Choi matrices obtained from executing QPT both
on a qasm_simulator and an ibm_perth quantum computer. These reconstructions
depict both the real ($\mathrm{Re}({\cal C}{\cal E})$) and imaginary
($\mathrm{Im}({\cal C}{\cal E})$) components. Concurrently, Figure 7 showcases
the Hinton diagrams, providing further elucidation of the quantum process
tomography outcomes. Through the utilization of QPT experiments, we ascertain
a process fidelity of $97.27098270\%$ and $88.9938260\%$ for the QPT
experiments conducted for the SQSCZ gate using the qasm_simulator and the IBM
real quantum machine ibm_perth, respectively.

Table 3: The experimental system attributes were observed while executing the
experimental implementation of the two-qubit SQSCZ gate for $7,168$ shots on
IBM Quantum’s quantum computer, named ”ibm_perth”. The Qiskit runtime time
usage amounted to 5 seconds.

$qubit~{}[i]$ | $T1(\mu s)$ | $T2(\mu s)$ | $\omega/2\pi\textrm{(GHz)}$ | $\gamma/2\pi\textrm{(GHz)}$ | $\xi(R)$ | $\zeta(\%)$ | $\eta(\%)$ |  $\delta$ (ns)
---|---|---|---|---|---|---|---|---
$qubit~{}[0]$ | 156.94281 | 81.627309 | 5.157568136 | -0.341524 | 0.0280000 | 0.0285999 | 0.0274 | 721.77777
$qubit~{}[1]$ | 89.705850 | 47.640857 | 5.033544687 | -0.344368 | 0.0285999 | 0.0288 | 0.0284 | 721.77777
$qubit~{}[2]$ | 18.130611 | 52.050573 | 4.862651686 | -0.347272 | 0.0282000 | 0.0293999 | 0.0270 | 721.77777
$qubit~{}[3]$ | 198.30965 | 170.40818 | 5.125102944 | -0.340441 | 0.0161000 | 0.0172 | 0.0150 | 721.77777
$qubit~{}[4]$ | 123.95948 | 87.855210 | 5.159217225 | -0.333366 | 0.0276000 | 0.0244 | 0.0308 | 721.77777
$qubit~{}[5]$ | 166.40637 | 47.179423 | 4.978593106 | -0.346022 | 0.0257000 | 0.0288 | 0.0226 | 721.77777
$qubit~{}[6]$ | 201.59061 | 246.67977 | 5.156639991 | -0.340454 | 0.0124999 | 0.01319999 | 0.0118 | 721.77777

Table 4:  The experimental system characteristics were closely monitored
duringthe execution of the Quantum Process Tomography (QPT) experiments for
the 2-qubit SQSCZ gate. The QPT experiment was iterated 4,000 times, employing
IBM Quantum’s quantum computer, ibm_perth. The total runtime amounted to 2
minutes and 40 seconds.

$qubit~{}[i]$ | $T1(\mu s)$ | $T2(\mu s)$ | $\omega/2\pi\textrm{(GHz)}$ | $\gamma/2\pi\textrm{(GHz)}$ | $\xi(R)$ | $\zeta(\%)$ | $\eta(\%)$ |  $\delta$ (ns)
---|---|---|---|---|---|---|---|---
$qubit~{}[0]$ | 130.04457328 | 73.58860043 | 5.1575647635 | -0.341524517 | 0.028399999 | 0.029399999 | 0.0274 | 721.77777
$qubit~{}[1]$ | 139.75002257 | 54.06849027 | 5.0335394509 | -0.344368702 | 0.028499999 | 0.027 | 0.03 | 721.77777
$qubit~{}[2]$ | 20.132049776 | 75.47632710 | 4.8626527977 | -0.347272472 | 0.027399999 | 0.031399999 | 0.0234 | 721.77777
$qubit~{}[3]$ | 181.07440147 | 194.4456264 | 5.1250989116 | -0.340441899 | 0.016999999 | 0.0194 | 0.014599999 | 721.77777
$qubit~{}[4]$ | 133.35414902 | 118.6893525 | 5.1592189326 | -0.333366537 | 0.028399999 | 0.0292 | 0.027599999 | 721.77777
$qubit~{}[5]$ | 80.657491205 | 176.7236497 | 4.9785968466 | -0.346022031 | 0.027800000 | 0.0300 | 0.0256 | 721.77777
$qubit~{}[6]$ | 146.35500245 | 230.4577368 | 5.1566401889 | -0.340454390 | 0.011900000 | 0.0153999999 | 0.0084 | 721.77777

##  VII Conclusion

In summary, quantum process tomography is an essential procedure aimed at
validating quantum gates and identifying shortcomings in configurations and
gate designs. Its recent utilization has played a crucial role in experimental
quantum computation and communication. In this study, we assess the SQSCZ
gate’s performance on a noisy intermediate-scale quantum computer through QPT
experiments conducted across diverse environments, employing both IBM
Quantum’s simulators (qasm_simulator) and a real quantum computer (ibm_perth).
The QPT experiments were conducted with 11,000 repetitions for each
measurement basis using the qasm_simulator, and with 4,000 shots on the
ibm_perth. The resulting measurement outcomes from all circuits were utilized
to reconstruct the Choi matrices, which were then compared with ideal
expectations. Our findings reveal comparable fidelities between theoretical
predictions and experimental implementations, shedding light on the accuracy
of implementations, measurement errors, and noise properties of the SQSCZ
gate. Specifically, we demonstrated a process fidelity (${\cal F_{P}}$) of
$97.27098\%$ and $88.99383\%$, respectively. These findings bear promising
implications for advancing both theoretical understanding and practical
applications within the domain of quantum computation.

##  VIII List of Abbreviations

NISQ | Noisy intermediate-scale quantum
---|---
QPT | Quantum process tomography
QST | Quantum state tomography
${\cal P}_{\rm{in(out)}}$ | Input (output) density matrix
${\cal E}$ | A quantum dynamical map (process)
$\chi_{mn}$ | A positive Hermitian matrix
$\widehat{W}_{m}$ | Operators constitute a complete basis
CPTP | Completely positive and trace-preserving
PTM | Pauli-Transfer-Matrix
$(.)^{T}$ | The matrix transposition
${\cal C}_{\cal E}$ | The Choi matrix
${\cal H}_{\mathrm{in(out)}}$ | The input (output) Hilbert spaces
$\Xi$ | Projector
$\textrm{Tr}^{\pounds}$ | The partial trace
ID | Identitiy gate
SX | The square root of X gate
$R_{Z}$ | The rotation about $z$-axis
Ph | Phase gate
CZ | The controlled-Z gate
CX | The controlled-X gate
$\sqrt{CZ}$ | The square root of controlled-Z
$\sqrt{SWAP}$ | The square root of SWAP gate
QFT | Quantum Fourier transform
Falcon r5.11H | A quantum processor by IBM Quantum
QV | Quantum voulume
${\cal F_{P}}$ | The process fidelity
qasm | Quantum assembly language
$qubit~{}[i]$ | The $i^{th}$ qubit
$T1$ | Relaxation time
$T2$ | Dephasing time
$\omega/2\pi$ |  | The qubit frequency
---|---|---
$\gamma/2\pi$ |  | The qubit anharmonicity
$\xi(R)$ |  | The qubit readout assignment error
$\zeta$ |  | The Probability of meas. 0 prep. 1
$\eta$ |  | The Probability of meas. 1 prep. 0
Re[.] |  | Real part
Im[.] |  | Imaginary Part
GHz |  | Giga hertz
MHz |  | Mega hertz
$\mu$s |  | Micro seconds
ns |  | Nano seconds

###### Acknowledgements.

“We acknowledge the use of IBM Quantum for this research. The views and
conclusions expressed by the author are their own and do not necessarily
reflect IBM Quantum’s official policy or position. This research received no
specific grant from any funding agency in the public, commercial, or not-for-
profit sectors.”

## Declaration of competing interest

“The author declare that they have no known competing financial interests or
personal relationships that could have appeared to influence the work reported
in this paper.”

## Data availability

The data sets produced and/or analyzed during the current study are
incorporated within this article.

## References

  * [1] M. AbuGhanem and H. Eleuch, “NISQ Computers: A Path to Quantum Supremacy,” arXiv preprint arXiv:2310.01431 [quant-ph], (2023). https://doi.org/10.48550/arXiv.2310.01431
  * [2] Dowling, J. P. and Milburn, G. J., “Quantum technology: the second quantum revolution,” Philosophical Transactions of the Royal Society of London A: Mathematical, Physical and Engineering Sciences 361, 1655–1674 (2003).
  * [3] Bennett, C. H. and Brassard, G., “Quantum cryptography: Public key distribution and coin tossing,” Proceedings of the ieee international conference on computers, systems, and signal processing, bangalore, india, (1984). (1984).
  * [4] M. A. Nielsen and I. L. Chuang, “Quantum computation and quantum information,” Cambridge University Press, 10th anniversary ed., (2011).
  * [5] Degen, C., Reinhard, F. and Cappellaro, P. “Quantum sensing,” Rev. Mod. Phys. 89, 035002 (2017).
  * [6] F. Arute et al., “Quantum supremacy using a programmable superconducting processor,” Nature 574, 505–510 (2019).
  * [7] H.-S. Zhong et al., “Quantum computational advantage using photons,” arXiv:2012.01625v1 [quant-ph], (2020).
  * [8] A. Deshpande et al., “Quantum computational advantage via high-dimensional gaussian boson sampling,” Sci. Adv. 8, eabi7894 (2022).
  * [9] H.-S. Zhong et al., “Phase-Programmable Gaussian Boson Sampling Using Stimulated Squeezed Light,” arXiv:2106.15534v2 [quant-ph] (2021).
  * [10] Y. Wu et al., “Strong quantum computational advantage using a superconducting quantum processor,” Phys. Rev. Lett. 127, 180501 (2021).
  * [11] I. L. Chuang and M. A. Nielsen, “Prescription for experimental determination of the dynamics of a quantum black box,” J. Mod. Opt. 44, 2455 (1997).
  * [12] J. F. Poyatos, J. I. Cirac, and P. Zoller, “Complete characterization of a quantum process: the two-bit quantum gate,” Phys. Rev. Lett. 78, 390 (1997).
  * [13] J. L. O’Brien, G. J. Pryde, A. Gilchrist, D. F. V. James, N. K. Langford, T. C. Ralph, and A. G. White, “Quantum Process Tomography of a Controlled-NOT Gate,” Phys. Rev. Lett. 93, 080502 (2004).
  * [14] Nielsen, M. A., Knill, E. and Laflamme, R. “Complete quantum teleportation using nuclear magnetic resonance,” Nature 396, 52 (1998).
  * [15] Childs, A. M., Chuang, I. L. and Leung, D. W. “Realization of quantum process tomography in NMR,” Phys. Rev. A 64, 012314 (2001).
  * [16] Myrskog, S. H., Fox, J. K., Mitchell, M. W. and Steinberg, A. M. “Quantum process tomography on vibrational states of atoms in an optical lattice,” Phys. Rev. A 72, 013615 (2005).
  * [17] Riebe, M., Kim, K., Schindler, P., Monz, T., Schmidt, P. O., Korber, T. K., Hansel, W., Haffner, H., Roos, C. F. and Blatt, R. “Process tomography of ion trap quantum gates,” Phys. Rev. Lett. 97, 220407 (2006).
  * [18] Lobino, M. et al. “Complete characterization of quantum-optical processes,” Science 322, 563–566 (2008).
  * [19] Howard, M. et al. “Quantum process tomography and linblad estimation of a solid-state qubit,” New Journal of Physics 8, 33 (2006).
  * [20] Kim, D. et al. “Quantum control and process tomography of a semiconductor quantum dot hybrid qubit,” Nature 511, 70 (2014).
  * [21] Jacob, K. V., Mirasola, A. E., Adhikari, S. and Dowling, J. P. “Direct characterization of linear and quadratically nonlinear optical systems,” Phys. Rev. A 98, 052327 (2018).
  * [22] M. AbuGhanem and H. Eleuch, “Two-qubit entangling gates for superconducting quantum computers,” Results in Physics 56, 107236 (2024).
  * [23] M. AbuGhanem and H. Eleuch, “Experimental characterization of Google’s Sycamore quantum AI on an IBM’s quantum computer,” Available at SSRN (2023). http://dx.doi.org/10.2139/ssrn.4299338
  * [24] M. AbuGhanem and H. Eleuch, “A Quantum State tomography study of Google’s Sycamore gate on an IBM’s quantum computer,” Available at SSRN (2023). http://dx.doi.org/10.2139/ssrn.4316581
  * [25] Shor, P. W. and Preskill, J. “Simple proof of security of the BB84 quantum key distribution protocol,” Phys. Rev. Lett. 85, 441–444 (2000).
  * [26] S.-K. Liao, W.-Q. Cai, W.-Y. Liu et al., “Satellite-to-ground quantum key distribution,” Nature 549(7670), 43–47 (2017).
  * [27] J.-G. Ren, P. Xu, H.-L. Yong et al., “Ground-to-satellite quantum teleportation,” Nature 549(7670), 70–73 (2017).
  * [28] Gisin, N., Ribordy, G., Tittel, W. and Zbinden, H. “Quantum cryptography,” Rev. Mod. Phys. 74, 145 (2002).
  * [29] Bienvenu, N., Perez-Garcia, B., Roux, F. S., McLaren, M., Rosales-Guzman, C., Zhang, Y., Mouane, O., Hernandez-Aranda, R. I., Konrad, T. and Forbes, A. “Characterizing quantum channels with non-separable states of classical light,” Nat. Phys. 13, 397 (2017).
  * [30] Muller, A., Zbinden, H. and Gisin, N. “Underwater quantum coding,” Nature 378, 449 (1995).
  * [31] Buttler, W. T., Hughes, R. J., Kwiat, P. G., Lamoreaux, S. K., Luther, G. G., Morgan, G. L., Nordholt, J. E., Peterson, C. G. and Simmons, C. M. “Practical free-space quantum key distribution over 1 km,” Phys. Rev. Lett. 81, 3283 (1998).
  * [32] Yin, J., Cao, Y., Li, Y. H., Ren, J. G., Liao, S. K., Zhang, L., Cai, W. Q., Liu, W. Y., Li, B., Dai, H., Li, M., Huang, Y. M., Deng, L., Li, L., Zhang, Q., Liu, N. L., Chen, Y. A., Lu, C. Y., Shu, R., Peng, C. Z., Wang, J. Y. and Pan, J. W. “Satellite-to-ground entanglement-based quantum key distribution,” Phys. Rev. Lett. 119, 200501 (2017).
  * [33] Bechmann-Pasquinucci, H. and Tittel, W. “Quantum cryptography using larger alphabets,” Phys. Rev. A 61, 062308 (2000).
  * [34] Cerf, N. J., Bourennane, M., Karlsson, A. and Gisin, N. “Security of quantum key distribution using d-level systems,” Phys. Rev. Lett. 88, 127902 (2002).
  * [35] Molina-Terriza, G., Torres, J. P. and Torner, L. “Twisted photons,” Nature Physics 3, 305 (2007).
  * [36] Erhard, M., Fickler, R., Krenn, M. and Zeilinger, A. “Twisted photons: New quantum perspectives in high dimensions,” Light: Sci. and Appl. 7, 17146 (2018)
  * [37] Frédéric Bouchard, Felix Hufnagel, Dominik Koutný, Aazad Abbas, Alicia Sit, Khabat Heshami, Robert Fickler, and Ebrahim Karimi, “Quantum process tomography of a high-dimensional quantum communication channel,” Quantum 3, 138 (2019).
  * [38] M. D. Choi, “Completely positive linear maps on complex matrices,” Linear Alg. and Its Appl. 10, 285 (1975).
  * [39] A. Jamiołkowski, “Linear transformations which preserve trace and positive semidefiniteness of operators,” Rep. Math. Phys. 3, 275 (1972).
  * [40] IBM Quantum, https://quantum-computing.ibm.com, (2024).
  * [41] K. Kraus. States, “Effects, and Operations,” Springer-Verlag. Berlin. (1983).
  * [42] Daniel Greenbaum, “Introduction to Quantum Gate Set Tomography,” arXive preprints, arXiv:1509.02921 [quant-ph], (2015).
  * [43] Wood, C. J., Biamonte, J. D. and Cory, D. G. “Tensor networks and graphical calculus for open quantum systems,” Quantum Inf. Computat. 15, 0579–0811 (2015).
  * [44] S. T. Merkel, J. M. Gambetta, J. A. Smolin, S. Poletto, A. D. Corcoles, B. R. Johnson, C. A. Ryan, and M. Steffen, “Self-consistent quantum process tomography,” Phys. Rev. A 87, 062119 (2013).
  * [45] George C. Knee, Eliot Bolduc, Jonathan Leach, and Erik M. Gauger, “Quantum process tomography via completely positive and trace-preserving projection,” Phys. Rev. A 98, 062336 (2018).
  * [46] Torlai, G., Wood, C.J., Acharya, A. et al. “Quantum process tomography with unsupervised learning and tensor networks,” Nat Commun 14, 2858 (2023).
  * [47] M.W. Mitchell et al., “Diagnosis, prescription, and prognosis of a Bell-State filter by quantum process tomography,” Phys. Rev. Lett. 91, 120402 (2003).
  * [48] D’Ariano, G. M. and Lo Presti, P. “Quantum tomography for measuring experimentally the matrix elements of an arbitrary quantum operation,” Phys. Rev. Lett. 86, 4195–4198 (2001).
  * [49] Weinstein, Y. S. et al. “Quantum process tomography of the quantum Fourier transform,” J. Chem. Phys. 121, 6117–6133 (2004).
  * [50] Bialczak, R. C. et al. “Quantum process tomography of a universal entangling gate implemented with Josephson phase qubits,” Nat. Phys. 6, 409–413 (2010).
  * [51] Chow, J. M. et al. “Universal quantum gate set approaching faulttolerant thresholds with superconducting qubits,” Phys. Rev. Lett. 109, 060501 (2012).
  * [52] Shabani, A. et al. “Efficient measurement of quantum dynamics via compressive sensing,” Phys. Rev. Lett. 106, 100401 (2011).
  * [53] Krinner, S. et al. “Benchmarking coherent errors in controlled-phase gates due to spectator qubits,” Phys. Rev. Applied 14, 024042 (2020).
  * [54] Govia, L. C. G., Ribeill, G. J., Ristè, D., Ware, M. and Krovi, H. “Bootstrapping quantum process tomography via a perturbative ansatz,” Nat. Commun. 11, 1084 (2020).
  * [55] M. AbuGhanem and H. Eleuch, “Quantum tomography study of DB gate on an IBM’s quantum computer,” Available at SSRN (2023). http://dx.doi.org/10.2139/ssrn.4262095
  * [56] David P. DiVincenzo, “The Physical Implementation of Quantum Computation,” Fortschr. Phys. 48, 9-11 (2000).
  * [57] D. P. DiVincenzo, “Quantum computation,” Science 270, 5234 (1995).
  * [58] A. Barenco, C. H. Bennett, R. Cleve et al., “Elementary gates for quantum computation,” Phys. Rev. A 52, 3457 (1995).
  * [59] T. D. Ladd, F. Jelezko, R. Laflamme et al., “Quantum computers,” Nature 464, 45 (2010).
  * [60] M. J. Bremner et al., “Practical Scheme for Quantum Computation with Any Two-Qubit Entangling Gate,” Phys. Rev. Lett. 89, 247902 (2002).
  * [61] J. I. Cirac and P. Zoller, “Quantum computations with cold trapped ions,” Phys. Rev. Lett. 74 20, 4091 (1995).
  * [62] T. Sleator and H. Weinfrter, “Realizable Universal Quantum Logic Gates,” Phys. Rev. Lett. 74 4087 (1995).
  * [63] M. AbuGhanem, A. Homid, and M. Abdel-Aty, “Cavity control as a new quantum algorithms implementation treatment,” Front. Phys. 13 1, 130303 (2018).
  * [64] D. R. Simon, “On the power of quantum computation,” SIAM J. Comput. 26(5), 1474–1483 (1997).
  * [65] Yao Lu, S. Zhang, K. Zhang et al., “Global entangling gates on arbitrary ion qubits,” Nature 572, (2019).
  * [66] Guifré Vidal, “Efficient Classical Simulation of Slightly Entangled Quantum Computations,” Phys. Rev. Lett. 91, 147902 (2003).
  * [67] M. AbuGhanem et al., “Fast universal entangling gate for superconducting quantum computers,” [Manuscript submitted for publication]. (2024).
  * [68] M. AbuGhanem, “Properties of some quantum computing models,” Master’s Thesis, Ain Shams University (2019).
  * [69] John M. Martinis, Kevin Osborne, “Superconducting Qubits and the Physics of Josephson Junctions,” arXive preprints, arXiv:cond-mat/0402415 [cond-mat.supr-con], (2004).
  * [70] J. Zhang, A. M. Souza, F. D. Brandao, and D. Suter, “Protected quantum computing: Interleaving gate operations with dynamical decoupling sequences,” Phys.Rev. Lett. 112, 050502 (2014).


# Trade-off between Bagging and Boosting for quantum separability-entanglement
classification

Sanuja D. Mohanty  Dept. of Physics, International Institute of Information
and Technology, Bhubaneswar 751029 Odisha, India  Ram N. Patro  c116009@iiit-
bh.ac.in Dept. of ECE, International Institute of Information and Technology,
Bhubaneswar 751029 Odisha, India  Pradyut K. Biswal  Dept. of ECE,
International Institute of Information and Technology, Bhubaneswar 751029
Odisha, India  Biswajit Pradhan  Dept. of Physics, International Institute of
Information and Technology, Bhubaneswar 751029 Odisha, India  Sk Sazim
<EMAIL_ADDRESS>RCQI, Institute of Physics, Slovak Academy of Sciences,
845 11 Bratislava, Slovakia  Center for Theoretical Physics, Polish Academy of
Sciences, Aleja Lotników 32/46, 02-668 Warsaw, Poland

###### Abstract

Certifying whether an arbitrary quantum system is entangled or not, is, in
general, an NP-hard problem. Though various necessary and sufficient
conditions have already been explored in this regard for lower dimensional
systems, it is hard to extend them to higher dimensions. Recently, an ensemble
bagging and convex hull approximation (CHA) approach (together, BCHA) was
proposed and it strongly suggests employing a machine learning technique for
the separability-entanglement classification problem. However, BCHA does only
incorporate the balanced dataset for classification tasks which results in
lower average accuracy. In order to solve the data imbalance problem in the
present literature, an exploration of the Boosting technique has been carried
out, and a trade-off between the Boosting and Bagging-based ensemble
classifier is explored for quantum separability problems. For the two-qubit
and two-qutrit quantum systems, the pros and cons of the proposed random
under-sampling boost CHA (RUSBCHA) for the quantum separability problem are
compared with the state-of-the-art CHA and BCHA approaches. As the data is
highly unbalanced, performance measures such as overall accuracy, average
accuracy, F-measure, and G-mean are evaluated for a fair comparison. The
outcomes suggest that RUSBCHA is an alternative to the BCHA approach. Also,
for several cases, performance improvements are observed for RUSBCHA since the
data is imbalanced.

###### Contents

  1. I Introduction
  2. II Setting up the stage
    1. II.1 Supervised learning
    2. II.2 Combining CHA with supervised learning
    3. II.3 Overview of Bagging and Boosting Classifiers
    4. II.4 Imbalanced dataset
    5. II.5 Ensemble classifiers for imbalanced dataset
  3. III RUSBoost CHA (RUSBCHA)
  4. IV Experimental Setup
    1. IV.1 Dataset preparation
    2. IV.2 Performance measures
  5. V Results and Discussion
    1. V.1 Experiment 1
    2. V.2 Experiment 2
    3. V.3 Experiment 3
  6. VI Conclusion
  7. A Feature vector
  8. B Generating random density matrices in the code
  9. C List of Abbreviations

##  I Introduction

Nowadays, machine learning (ML) is being employed more to tackle and solve
harder problems in quantum information science. In recent years, it has been
applied in state classifications [1, 2, 3], state reconstruction [4],
parameter estimation [5], and many others [6, 7, 8, 9, 10, 11, 12, 13]. The
motivation behind using ML in quantum information is to get more insights into
problems where usual numerical techniques either fail or need more resources,
eg., the optimization tasks in high constraint or non-convex scenarios.

To decide whether an arbitrary quantum state is entangled or not is an NP-hard
problem [14]. It is one of the long-standing fundamental issues in
entanglement theory. A state of a composite system $\rho_{AB}$ is said to be
separable if $\rho_{AB}=\sum_{i}p_{i}\rho_{A}^{i}\otimes\rho_{B}^{i}$ for any
two subsystems $A$ and $B$, where $p_{i}$ $(\geq 0)$ represents classical
mixing probability with $\sum_{i}p_{i}=1$. Otherwise, it is an entangled
state. There exist numerous criteria to detect bipartite entanglement,
however, these criteria are less reliable for higher dimensional systems. For
example, the popular Peres-Horodecki criteria state that the separable states
are positive partial transpose (PPT) [15, 16], meaning for separable states
$\rho_{AB}^{T_{A}}\geq 0$, where $T_{A}$ denotes transposition on system $A$.
The criteria are necessary and sufficient for $d_{A}d_{B}\leq 6$, where $d$
denotes system dimension. Other extant method includes entanglement witness,
reduction criteria, cross-norm, or realignment criteria to name a few [17].
The most powerful technique is $k$-extension hierarchy, but it is notoriously
hard to compute due to its exponentially growing complexity with $k$ [18, 19].
Recently, in Ref.[1], it was studied that ML techniques are instrumental in
probing separability-entanglement classification. It was established that the
ML-based technique is more efficient in terms of speed and accuracy than all
extant methods. A couple more ML-based techniques were well studied for
quantum separable-entanglement classification using artificial neural networks
[20, 21].

Ref. [1] employed the convex hull approximation (CHA) to probe the
separability-entanglement boundary using a supervised learning scheme. To
reduce the error in classification using CHA, the bagging method [22] was
invoked. This new method is known as bagging CHA (BCHA). This method increases
the speed and accuracy of data manipulation as it divides the whole process
into smaller units, and then runs in parallel. Ref. [1] demonstrates their
results for two-qubits and two-qutrit systems with fairly high accuracy.

In this work, building on the approaches of Ref. [1], we propose an
alternative method that addresses some important issues with further accuracy
improvements for the separability-entanglement classification using ML. First,
a) we notice that the earlier work doesn’t address the issue of handling data
imbalance, and b) did not explore all extant performance measures in their
study.

##  II Setting up the stage

###  II.1 Supervised learning

Supervised learning is a method of developing artificial intelligence that
involves training a computer algorithm on input data that has been labeled for
a certain output [23]. In order to apply it to real-time data, the model is
trained until it can discover the underlying patterns and relationships
between the input data and the output labels, allowing it to produce accurate
classification results.

For supervised learning, the system is supplied with labeled data sets
throughout its training phase, which tell it what output is associated with
each specific input set. The trained model is then evaluated with test data,
which is labeled data with the labels hidden from the algorithm [24]. Further,
the unlabeled testing data is used to determine how well the algorithm
performs the classification task [25].

To create the learning dataset, we consider bipartite quantum state
$\rho_{AB}$ of dimension $d_{A}\otimes d_{B}$ in
$\mathcal{H}_{A}\otimes\mathcal{H}_{B}$. Arbitrary density matrix $\rho_{AB}$
$\in\mathcal{H}_{A}\otimes\mathcal{H}_{B}$ can be represented by real vector
${\bm{x}_{i}}$ $\in\mathcal{V}$ ($=\mathbb{R}^{d_{A}^{2}d_{B}^{2}-1}$) as
$\rho^{\dagger}=\rho$ and ${\rm Tr}[\rho]=1$. We call such a vector _feature
vector_ [see Appendix A for detail]. The training dataset is then defined as
$\Omega_{\rm train}=\\{(\bm{x}_{i},y_{i})|i=1,\cdots n\\}$, where $x_{i}$ is
the $i^{th}$ sample and $y_{i}$ is its corresponding class label, which is
represented as, $y_{i}=1(0)$ if it is separable (entangled). Data labeling for
$d_{A}d_{B}\leq 6$ is performed by using PPT criteria. However, for higher
dimensions, the labeling is done as per the Appendix-C of Ref. [1].

In supervised learning, the main aim is to find a classifier (indicator
function) $\Theta:\mathcal{V}\to\\{0,1\\}$ which will fit the training data at
best among a class of functions $\mathcal{F}$. As the present quantum
entanglement is a binary classification problem, the error expresses the miss
classification rate over two classes. For any training data $\Omega_{\rm
train}$ consisting of $n$ samples, each associated with feature vector
$\mathcal{V}$ and a target class label $y_{i}$ ($\in\\{0,1\\}$); the loss
function $\mathbb{L}$ for any binary classifier $\Theta$ can be represented as

$\mathbb{L}(\Theta,\Omega_{\rm
train})=\frac{1}{n}\sum_{i=1}^{n}\mathbbm{1}[y_{i}\neq\Theta(\bm{x}_{i})],$

where $\mathbbm{1}[\cdot]$ is a truth function of its argument. For any test
data $\Omega_{\rm test}$, the value of function $\mathbb{L}(\Theta,\Omega_{\rm
test})$ depicts the generalization error from $\Omega_{\rm train}$ to
$\Omega_{\rm test}$.

It was found that among numerous extant supervised learning algorithms, eg.,
support vector machine (SVM) [26], decision tree [27], boosting [28], etc do
not provide acceptable accuracy for separability problem [1]. This is due to
the complex structure of the set of separable states. This led authors of Ref.
[1] to the following consideration.

###  II.2 Combining CHA with supervised learning

The set of all separable states, $\Omega_{1}$, is convex and compact, and its
exterior points are all pure product states. Using this fact, one can sample
$\Omega_{1}$ using convex hull ($\mathds{C}$) of $m$ number of product states,
$\\{\bm{c}_{i}\\}\in\mathcal{V}$, i.e., $\mathds{C}:={\rm
conv}\\{\bm{c}_{i}~{}|i=1,\dots,m\\}$. The $\mathds{C}$ is the CHA of
$\Omega_{1}$, and one can decide if an unknown state $\rho$ is separable or
not by examining whether its feature vector $\bm{x}$ is in $\mathds{C}$.
Equivalently, it is the solution of following linear programming:

$\displaystyle\max~{}\alpha~{}~{}~{}{\rm
s.t}.~{}~{}~{}\alpha\bm{x}\in\mathds{C},~{}~{}~{}{\rm i.e.},$
$\displaystyle\alpha\bm{x}=\sum_{i=1}^{|\mathds{C}|}\lambda_{i}\bm{c}_{i},~{}~{}\lambda_{i}\geq
0,~{}~{}\sum_{i}\lambda_{i}=1,$ (1)

where $\alpha$ has functional dependence on both $\mathds{C}$ and $\bm{x}$. If
$\bm{x}$ is in $\mathds{C}$, then the corresponding state, $\rho$, is
separable, else $\rho$ is an entangled state with high possibility. More
specifically $\rho$ is separable when $\alpha\geq 1$ and entangled otherwise.
We denote a maximal $\alpha$ for a chosen $m$-value as $\alpha_{\max}^{m}$. If
we increase $m$ (to better approximate $\mathds{C}$), we will achieve better
classification. It is evident that adding more exterior points in convex
approximation will increase the accuracy of the above algorithms, however, it
is really time-consuming. To overcome this, Ref. [1] used CHA in combination
with supervised learning. Now, training data is defined as $\Omega_{\rm
train}=\\{(\bm{x}_{i},\alpha_{i},y_{i})|i=1,\dots,n\\}$ and the loss function
of classifier $\Theta$ is redefined as

$\mathbb{L}(\Theta,\Omega_{\rm
train})=\frac{1}{n}\sum_{i=1}^{n}\mathbbm{1}[y_{i}\neq\Theta(\bm{x}_{i},\alpha_{i})].$
(2)

Where $\alpha_{i}$ is the outcome of CHA for $i$-th random density matrix
after solving the linear programming for finding $\bm{x}$ in $\mathds{C}$.
Note that, CHA uses a threshold $\alpha\geq 1$ to classify as 1(0). The values
of $\alpha$ acts as another feature for the classifier to learn the model. In
Ref [1] bagging-based classification is performed on this feature space, known
as Bagging CHA (BCHA). More information on the Bagging and Boosting approaches
is discussed further.

###  II.3 Overview of Bagging and Boosting Classifiers

An ensemble meta-estimator called a bagging classifier fits base classifiers
one at a time to random subsets of the original dataset, and then it
aggregates the individual predictions (either by voting or by averaging) to
provide a final prediction. By adding randomization to the process of building
a black-box estimator (such as a decision tree), a meta-estimator of this kind
can often be used to lower the variance of the estimator.

A training set is created by randomly selecting $M$ instances (or pieces of
data) from the original training dataset (of size $N$), and used to train each
base classifier in parallel. Each base classifier’s training set is distinct
from the others. In the resultant training set, many of the original data
might be replicated while others might not. An overview of Bagging classifiers
is presented in Fig. 1.

Figure 1: Overview of Bagging classifier: Multiple learners are created by
generating additional data points. The new data points are created randomly
with a uniform probability as before. Generally, the created $N$ learners are
parallel and are further averaged to obtain the final learning error defined
as $e=\frac{1}{N}\sum_{i=1}^{N}e_{i}$.

A number of weak classifiers are combined in the broad ensemble approach known
as ”boosting” to produce a strong classifier. In order to do this, a model is
first constructed using the training data, and a second model is then
developed in an effort to fix the errors in the first model. The training set
is predicted exactly or a predetermined number of models are added, depending
on which comes first. AdaBoost [29] was the first really successful boosting
algorithm developed for binary classification. An overview of Boosting
classifiers is presented in Fig. 2.

Figure 2: Overview of Boosting classifier: Similar to the Bagging approach,
the Boosting classifier also generates multiple data points. But, unlike
parallel in Bagging, the Boosting approach sequentially learns the error from
the previous learner and assigns a higher weight to the miss classified data,
and random sampling with weighted replacement is carried out. Also, another
set of weights assigned to the learners

are further accumulated to find the final weighted average error defined as
$e=\sum_{i=1}^{N}w_{i}e_{i}$.

Both boosting and bagging fall under the category of ”ensemble learning.”
Combining many weak learners to create a hybrid categorization system. Most
often, ”ensemble learning” refers to trained weak decision ensemble trees.

###  II.4 Imbalanced dataset

Imbalanced dataset refers to an unequal distribution of class samples within a
dataset. Such unequal distribution of class samples reduces the training
performance of the classifiers, and hence the classification results on the
testing data are also affected.

In the present context, the volume of entangled states is far more than the
separable states, making the dataset imbalanced. For more details on the
experimented datasets, see Section IV.1. From the discussion in Section IV.1,
we can observe that the prevalence differences are high for both datasets and
hence they are highly imbalanced.

This demands a classifier that can handle data imbalance issues and can be
more suitable for quantum separability-entanglement classification problems.
Which is discussed in the next section.

Also, for such imbalanced datasets, the learning performance of any ML
approach is greatly affected [30] and needs a careful performance evaluation.
Such performance measures are discussed in Section IV.2.

###  II.5 Ensemble classifiers for imbalanced dataset

It has been well studied that, for imbalanced data, the SVM classifier may be
biased towards the majority class [31]. A modification of SVM has already been
presented, incorporating random under-sampling (RUS) for an unbalanced dataset
[32] by removing the samples randomly from the training set. For highly
unbalanced data, synthetic minority oversampling technique (SMOTE) [33, 34]
has been applied towards classification, where, it generally over-sample the
minority class to create synthetic data points. So further incorporation of
SMOTE to Boosting approach may be effective for classification. When
oversampling is performed by duplicating examples, it may lead to over-fitting
[35]. So, further modification by incorporating the under-sampling may help in
the performance improvement of the classifier. Instead of over-sampling the
minority classes, under-sampling the majority classes also may help in
improving the classifier results. The RUS randomly removes examples from the
majority class until the desired class distribution is found [36]. Such
integration with Boosting is RUSBoost [36], which is a hybrid approach
combining random under-sampling, SMOTE, and Adaptive Boost (AdaBoost)
classifier.

For ensemble learning, bagging and boosting are generally applied (see Fig. 1
and Fig. 2). Already the Bagging-based CHA (BCHA) is proposed [1], reporting
higher accuracy than CHA. But, as the data is highly unbalanced, the accuracy
evaluation should be twofold – 1) Overall accuracy (OA) and 2) Average
accuracy (AA). For more details on the performance measures OA and AA, see
IV.2. OA is the number of correctly classified test samples per total samples
under test. While AA is the sum of accuracy for each class predicted per the
total number of classes (average of each accuracy per class). Hence, although
the reported OA [1] is higher, we evaluated the AA of BCHA, which is of less
margin than the CHA approach. This demands further improvement in the
classifier which can take care of both the OA and AA for separability-
entanglement classification.

As the experimented data set is highly unbalanced (refer Section IV.1), the
RUSBoost approach is explored for separability-entanglement classification and
is validated over the state-of-the-art approaches. The subsequent section
describes the RUSBoost ensembled CHA classifier.

##  III RUSBoost CHA (RUSBCHA)

Initially, all examples in the training data set are assigned equal weights.
During each iteration of AdaBoost, a weak hypothesis is formed by the base
learner. The error associated with the hypothesis is calculated, and the
weight of each example is adjusted such that wrongly classified examples have
their weights increased while correctly classified samples have their weights
decreased. Therefore, subsequent iterations of boosting will generate
hypotheses that are more likely to correctly classify the previously
mislabeled examples. After all, iterations are completed, a weighted vote of
all hypotheses is used to assign a class to the unlabeled samples.

Data sampling techniques attempt to alleviate the problem of class imbalance
by adjusting the class distribution of the training data set. This can be
accomplished by either removing examples from the majority class (under-
sampling) or adding examples to the minority class (oversampling).

SMOTE adds new artificial minority examples by extrapolating between
preexisting minority instances rather than simply duplicating original
examples. The newly created instances cause the minority regions of the
feature space to be fuller and more general.

The RUSBoost takes advantage of all these approaches by combining them. A
detailed discussion on the RUSBoost approach can be found in [36].

Although significant classifier performance improvement is observed [1] in the
case of BCHA as compared to standalone CHA, some limitations exist which are
discussed in Section I. So, it can be further improvised in two ways 1) by
replacing the classifier and 2) by increasing the feature space by proper
feature extraction technique. Presently the first case is explored by
incorporating the RUSBCHA classifier for possible improvement in the
classification results leaving scope to explore the feature extraction
techniques as future work.

##  IV Experimental Setup

All the classifications were carried out on two kinds of feature spaces 1)
vector represented $\rho$ ($d^{2}-1$ dimensional feature space), 2) vector
represented $\rho$ with CHA calculated $\alpha_{\max}^{m}$ for a specific $m$
($d^{2}$ dimensional feature space). The experiments are carried out for both
the two-qubit and two-qutrit systems. Five different techniques such as;
Bagging, Boosting were tested on raw $d^{2}$-1 (for two-qubit system $d$=4 and
for two-qutrit system $d$=9) dimensional feature vector $\bm{x}$, CHA with
only one $\alpha_{\max}^{m}$, while, the BCHA and RUSBCHA are trained with
both the $\bm{x}$, and $\alpha_{\max}^{m}$. Their associated feature spaces
are presented in Table 1.

| BAGGING | BOOSTING | CHA | BCHA | RUSBCHA
---|---|---|---|---|---
Feature space |  $d^{2}$-1 |  $d^{2}$-1 |  $d^{2}$-1 | $d^{2}$ | $d^{2}$
Two qubit | 15 | 15 | 15 | 16 | 16
Two qutrit | 80 | 80 | 80 | 81 | 81
Table 1: Various experimented classifiers with their associated feature space
(dimensions).

The dataset details and the performance evaluators are presented below.

###  IV.1 Dataset preparation

The total data space $\Omega$ is a combination of the separable subspace
$\Omega_{1}$ and entangled subspace $\Omega_{0}$; such that
$\Omega=\Omega_{1}\cup\Omega_{0}$ and $\Omega_{1}\cap\Omega_{0}=\emptyset$
(see Fig 3). Two datasets, representing the feature vectors of random density
matrices for two-qubit and two-qutrit systems respectively, are supplied with
their class labels in [37]. The procedure for creating the random separable
and entangled states can be referred to in the BCHA manuscript [1]. The total
and class-specific training and testing sample information for the pair of the
experimented datasets; namely two-qubit and two-qutrit system, are presented
in Table 2 and Table 3 respectively. Approximate 50% samples are randomly
selected for training and the remaining 50% samples are used for testing to
evaluate the performances of ML algorithms.

The maximized parameter, $\alpha_{\max}^{m}$ for CHA (with varying $m$) of 1)
two-qubit system with $m=[1000,2000,..,10000]$, and 2) two-qutrit system with
$m=[10000,20000,..,100000]$) were also obtained from [1, 37]. The minimization
was made by solving the linear programming defined in Eq.(1).

Figure 3: Data space $\Omega$ as a combination of entangled $\Omega_{0}$ and separable $\Omega_{1}$ subspaces. $c_{i}$ represents the pure product states. Class (label) | Total | Training | Testing
---|---|---|---
Separable (1) | 2814 | 1388 | 1426
Entangled (0) | 37186 | 18612 | 18574
All sample | 40000 | 20000 | 20000
Table 2: Dataset description of experimented training, testing, and total samples for two-qubit systems. Class (label) | Total | Training | Testing
---|---|---|---
Separable (1) | 6751 | 3338 | 3413
Entangled (0) | 13249 | 6662 | 5687
All sample | 20000 | 10000 | 10000
Table 3: Dataset description of experimented training, testing, and total
samples for two-qutrit systems.

From Table 2 and Table 3, we can observe that the class samples are unequally
distributed within the dataset. A prevalence difference for a binary
classification represents the degree of imbalance in the dataset. The dataset-
specific prevalence difference of class samples can be interpreted as, for:

  * •

Two-qubit dataset (Table 2) :
$\left|\frac{2814}{40000}-\frac{37186}{40000}\right|=0.8593$.

  * •

Two-qutrit dataset (Table 3):
$\left|\frac{6751}{20000}-\frac{13249}{20000}\right|=0.3249$.

For a balanced dataset, the prevalence difference must approach $0$. However,
we can observe that the prevalence difference for the two-qubit dataset is
high (0.86) and for the two-qutrit dataset, it is comparatively low (0.32).
This clearly signifies that the experimented dataset is highly imbalanced. For
such imbalanced datasets, the learning performance of any ML approach is
greatly affected [30] and needs a careful performance evaluation. Such
performance measures are discussed further.

###  IV.2 Performance measures

For ease of understanding the binary classification, the confusion matrix is
presented in Fig. 4. In the figure, columns represent the original class
labels (supplied with the data) as _true_ and _false_ , similarly each row
represents the outcome of the classifier.

Figure 4: Confusion matrix for binary classification.

True positive (TP) and true negative (TN) are defined as both the original
(ground truth) and the obtained (classified) class labels are true and false
respectively. The contradictions are presented as false positive (FP) and
false negative (FN) which are off-diagonal in the confusion matrix. Let $N$
number of samples be tested, i.e., $N=\sum\left(TP+TN+FP+FN\right)$. So,
higher TP and TN values lead to better accuracy; on the contrary, higher FP
and FN values reject the classifier.

Now we can define overall accuracy (OA) as

$OA=\frac{TP+TN}{N},$

and the overall error (OE) as $OE=1-OA$.

For binary classification, let, out of $N$ tested samples, there are $N_{1}$
and $N_{2}$ samples labeled as _true_ and _false_ respectively, (where
$N=N_{1}+N_{2}$). The average accuracy (AA) is the mean accuracy obtained for
each class and is defined as

$AA=\frac{1}{2}\left(\frac{TP}{N_{1}}+\frac{TN}{N_{2}}\right).$

and the average error (AE) as $AE=1-AA$.

Similarly, other important measures such as sensitivity
($s=\frac{TP}{TP+FN}$), specificity ($r=\frac{TN}{N}$), Precision
($k=\frac{TP}{TP+FP}$), F-measure and G-mean can be incorporated for
validating the classification results. We will use the following two for our
analysis:

$\mbox{F-measure}=2\left(\frac{k\times s}{k+s}\right),\>\>\mbox{and}\>\>\mbox{
G-mean}=\sqrt{s\times r}.$

Higher values of OA, AA, F-measure, and G-mean are desirable for evaluating
the performance of a classifier.

##  V Results and Discussion

We used both the datasets (see Section IV.1) and all the performance measures
described in Section IV.2, to compare the proposed RUSBCHA and other state-of-
art classifiers in terms of figures. For the robust representation of
performances on the experimented data, all the classification performance
measures are averaged over 30 independent evaluations.

The Bagging and Boosting classifier only incorporates the $d^{2}$-1
dimensional feature vector $\bm{x}$. The classification performance as; AE,
F-measure, G-mean, and OE; for two-qubit and two-qutrit systems are presented
in Fig. 5 (a) and Fig. 5 (b) respectively. For the two-qubit system, (Fig. 5
(a)) it is observed that the proposed Boosting approach outperforms the
Bagging approach in terms of F-measure, G-mean, and AE. While marginal
deviation is observed for OE. Similarly, for the two-qutrit system (Fig. 5
(b)), improvement is observed for G-mean and AE.

Figure 5: Classification results of the raw data without considering the CHA
($\alpha$) for (a) two-qubit and (b) two-qutrit system.

According to both the CHA and BCHA approaches, if $\alpha_{\max}^{m}\geq 1$,
$\bm{x}$ is separable; else, $\bm{x}$ is highly possible to be an entangled
state. Hence, our proposed RUSBCHA classifier also incorporates both the
feature vectors $\bm{x}$ and $\alpha_{\max}^{m}$. To find the trade-off
between the state-of-the-art BCHA and the proposed RUSBCHA approach, further
experiments are made on both two-qubit and two-qutrit datasets. These
experiments include:

  * •

Experiment 1: Performance evaluation of classifiers over varying $m$.

  * •

Experiment 2: Performance evaluation of classifiers over varying percentages
of training and testing samples.

  * •

Experiment 3: Performance evaluation of classifiers on varying prevalence
difference of dataset.

###  V.1 Experiment 1

In this experiment, the CHA, BCHA, and proposed RUSBCHA classifiers are
compared over varying $m$ for both two-qubit and two-qutrit datasets.
Experimental results are shown in Fig. 6 and Fig. 7.

For a two-qubit system, from the Fig. 6(b), it can be observed that the AE of
BCHA is higher for all values of $m$ as compared to CHA and RUSBCHA
approaches. The BCHA performance has almost 40% error for the lower value of
$m$. It can also be observed that, for lower values of $m$, the performances
of CHA and RUSBCHA are similar, while, for higher values of $m$ RUSBCHA has
lower AE values. This clearly signifies that the proposed RUSBCHA is less
biased to the majority classes and hence the average accuracy is higher in
comparison to other state-of-approaches. A similar interpretation also can be
seen in Fig. 6(d).

From the Fig. 6(a), it can be observed that the OE of BCHA has lower values,
and hence its performance is better for lower values of $m$ in comparison to
RUSBCHA and CHA approaches. While the proposed RUSBCHA has intermediate
performance in comparison to other state-of-approaches. However, in Fig. 6(c),
the F-measure performances are equivalently similar for all approaches.

Figure 6: Classification results of the two-qubit system, considering the CHA
($\alpha$).

On the other hand, for the two-qutrit system (Fig. 7), both the BCHA and
RUSBCHA have similar performances over varying $m$ with significant
performance improvements as compared to the state-of-art CHA approach.

Figure 7: Classification results of the two-qutrit system, considering the CHA
($\alpha$).

In this experiment, you can observe better performance of proposed RUSBCHA
approach for two-qubit dataset in comparison to BCHA and CHA approaches. While
similar performances are observed for both RUSBCHA and BCHA for two-qutrit
datasets. To find the rationale for performance differences of these two
datasets, further experiments are carried out.

###  V.2 Experiment 2

In literature, it is proved that several machine learning techniques such as
neural network and deep learning require a large number of samples to train.
The above problem may occur due to the sensitivity of the classifier to the
percentage of training samples. In experiment 1, $50$% of samples are trained
and the rest are tested. Hence, further validation of the approaches is
carried out with varying training ($10$%-$50$%) and testing (90%-50%) scales,
and the performances are presented in Fig. 8 and Fig. 9 for two-qubit and two-
qutrit systems respectively. Note that, for this experiment, the total samples
are the same as Table 2 and Table 3 for the respective datasets. In this
experiment, $m$ is set as 2000 and 20000 for two-qubit data and two-qutrit
data respectively.

Figure 8: Obtained Overall Accuracy and Average Accuracy for the two-qubit
system over varying percentage (%) of training samples ($m$=2000). Figure 9:
Obtained Overall Accuracy and Average Accuracy for the two-qutrit systems over
varying percentage (%) of training samples ($m$=20000).

From the Fig. 8(a), it can be observed that OA of BCHA is 2.5% more than
RUSBCHA, while in the Fig. 8(b) AA of RUSBCHA is more than 15% better than
BCHA. However, the results of these classifiers do not vary by the variation
in training percentages. Therefore, performance of both the classifiers is not
sensitive to the number of training samples. For the two-qutrit data, in Fig.
9(a) and Fig. 9(b), you can also observe similar results. However, the AA
performances in Fig. 8(b) and Fig. 9(b) suggests that the RUSBCHA performs
better than BCHA, specifically for two-qubit dataset. Note in this respect
that the prevalence difference of the two-qutrit dataset ($0.3249$) which is
comparatively low referring to the prevalence difference of the two-qubit
dataset ($0.8593$) for this experiment. This further suggests that doing
further experiments to test both the classifiers with varying prevalence
difference ratios might provide us some clue on how these classifiers work for
imbalanced datasets.

###  V.3 Experiment 3

The above experiments were performed with two-qubit and two-qutrit datasets as
mentioned in Table 2 and Table 3 respectively. From these tables, you can
observe that the separable samples are only 7% and 33% of the total samples
for two-qubit and two-qutrit datasets, respectively. To test the performance
of classifiers for different prevalence differences, we created imbalanced
datasets of different prevalence differences for both two-qubit and two-
qutrit.

Table 4: Description of imbalanced datasets created from the original two-qubit dataset of Table 2. Number of Samples |  Prevalence Difference
---|---
Separable | Entangled | Total
1800 | 37186 | 38986 | 0.907
2814 | 33000 | 35814 | 0.842
2814 | 18000 | 20814 | 0.729
2814 | 14000 | 16814 | 0.665
2814 | 10000 | 12814 | 0.560
2814 | 8000 | 10814 | 0.479
2814 | 5500 | 8314 | 0.323
2814 | 4500 | 7314 | 0.230
2814 | 3500 | 6314 | 0.108
2814 | 3000 | 5814 | 0.031

Table 4 shows the description of created imbalanced datasets for two-qubits.
In this table, each row describes a dataset which is a subset of the dataset
described in Table 2. For each created dataset subset, its number of
separable, entangled, and total samples are represented. Also for each entry
in the table, the prevalence difference of the respective dataset is
mentioned. One notices the prevalence difference values range approximately
from $0$ to $0.9$. The value $0$ represents the dataset is balanced, and value
$0.9$ represents the dataset is highly imbalanced. A similar interpretation
for the two-qutrit dataset can be done from the Table 5.

Table 5: Description of imbalanced datasets created from the original two-qutrit dataset of Table 3. Number of Samples |  Prevalence Difference
---|---
Separable | Entangled | Total
600 | 13249 | 13849 | 0.913
1380 | 13249 | 14629 | 0.811
2200 | 13249 | 15449 | 0.715
3200 | 13249 | 16449 | 0.610
4200 | 13249 | 17449 | 0.518
5500 | 13249 | 18749 | 0.413
6751 | 13000 | 19751 | 0.316
6751 | 10500 | 17251 | 0.217
6751 | 8500 | 15251 | 0.114
6751 | 7000 | 13751 | 0.018

Fig. 10 shows the classifier performances over the varying prevalence of two-
qubit data. In the figure, the performances are averaged over 30 iterations,
and in each iteration, a new subset of the dataset is created with varying
prevalence differences (Table 4). For this experiment, we fixed these
parameters $m$=2000, and 50% training samples.

It is observed from the Fig. 10(a) that the OA of both BCHA and RUSBCHA are
similar up to 0.6 prevalence difference. However, afterward, there is a minor
improvement of OA for BCHA approach in comparison to RUSBCHA approach. From
the Fig. 10(b) it can be observed that both BCHA and RUSBCHA performances are
similar up to 0.5 prevalence difference. However, afterward, there is a sharp
decline of AA for BCHA in comparison to RUSBCHA.

Figure 10: Overall Accuracy and Average Accuracy of BCHA and RUSBCHA over
varying prevalence difference of the two-qubit data.

Fig. 11 shows the classifier performances over the varying prevalence of two-
qutrit data. In the figure, the performances are averaged over 30 iterations,
and in each iteration, a new subset of the dataset is created with varying
prevalence differences (Table 5). For this experiment, we fixed these
parameters $m$=20000, and 50% training samples.

It is observed from the Fig. 11(a) that the OA of both BCHA and RUSBCHA are
similar up to 0.3 prevalence difference. However, afterward, there is a minor
improvement of OA for BCHA approach in comparison to RUSBCHA approach. From
the Fig. 11(b) it can be observed that both BCHA and RUSBCHA performances are
similar up to 0.25 prevalence difference. However, afterward, there is a sharp
decline of AA for BCHA in comparison to RUSBCHA.

Figure 11: Overall Accuracy and Average Accuracy of BCHA and RUSBCHA over
varying prevalence difference of the two-qutrit data.

From the results in Fig. 10 and Fig. 11, it can be observed that the
performance of the proposed RUSBCHA approach is consistent (almost a straight
line) over varying prevalence differences of data. So, it can be concluded
that the performance of RUSBCHA is not heavily affected by the data
imbalances.

Referring to our earlier observations, for Fig. 6: the reason for having good
AA of proposed RUSBCHA over BCHA; and for Fig. 7: the reason for having
similar performances of both RUSBCHA and BCHA can now be justified using Fig.
10 and Fig. 11 respectively. Since the prevalence difference of two-qubit data
is 0.8593 our proposed RUSBCHA performs better than BCHA. While the prevalence
difference of two-qutrit data is 0.3249, hence, both BCHA and RUSBCHA
performances are similar.

Hence, we can conclude that the RUSBCHA can be an alternative to the BCHA
approach and also can be a better classifier to deal with highly imbalanced
datasets. Overall, the ensemble learning is helpful for better understanding
of separability-entanglement problem, when compared to the stand-alone CHA
approach.

##  VI Conclusion

The necessity of a separability-entanglement classifier is well-known in the
quantum information forum. Although various necessary and sufficient criteria
like PPT have been proposed in the past, still, they cannot be generalized for
higher dimensions. The ML approaches are vastly exploited in the general data-
mining perspective, while the discussions and applications are limited in
quantum information processing. Similar to BCHA, we proposed RUSBCHA as an
alternative ML-based solution for the quantum separability problem. The
proposed RUSBCHA approach for quantum separability problem shown improvements
in AE for the two-qubit system; while having similar responses for the two-
qutrit systems in comparison to CHA. As the data is highly unbalanced,
standard performance measures like OE, AE, F-measure, and G-mean are
evaluated. The results suggest incorporating a proper ML approach to classify
the separability-entanglement criteria with proper performance matrices. Also,
the proposed RUSBCHA can be an alternative to CHA which can deal with the
unbalanced dataset that may reduce the over-fitting error of the classifier.

In order to evaluate the effectiveness of the classifier, the feature
extraction is unexploited here, however, this can be a further direction of
research to improve the classification performance. Also, other ML approaches
can be exploited and validated further.

###### Acknowledgements.

SS acknowledges funding through Pasific program call 2 (Agreement No.
PAN.BFB.S.BDN.460.022 with the Polish Academy of Sciences). This project has
received funding from the European Union’s Horizon 2020 research and
innovation programme under the Marie Skłodowska- Curie grant agreement No
847639 and from the Ministry of Education and Science. SS also acknowledges
the financial support through DEQHOST (APVV-22-0570) and DESCOM
(VEGA-2/0183/21) during his stay at IPSAS, Bratislava.

## Author declarations

The authors have no conflicts to disclose.

## Code and Data Availability Statement

We have uploaded the code and the data created for our analysis in the
following open GitHub repository: https://github.com/ram-patro/RUSBCHA.

Note that the earlier repository, QMLab [37] created by the authors of Ref.
[1] is no longer available. Our repository given above includes all of the
analysis by QMLab also.

## References

  * [1] S. Lu, S. Huang, K. Li, J. Li, J. Chen, D. Lu, Z. Ji, Y. Shen, D. Zhou, B. Zeng, Physical Review A 98(1), 012315 (2018)
  * [2] C. Harney, S. Pirandola, A. Ferraro, M. Paternostro, New Journal of Physics 22(4), 045001 (2020).  DOI 10.1088/1367-2630/ab783d.  URL https://doi.org/10.1088/1367-2630/ab783d
  * [3] S. Ahmed, C. Sánchez Muñoz, F. Nori, A.F. Kockum, Phys. Rev. Research 3, 033278 (2021).  DOI 10.1103/PhysRevResearch.3.033278.  URL https://link.aps.org/doi/10.1103/PhysRevResearch.3.033278
  * [4] S. Ahmed, C. Sánchez Muñoz, F. Nori, A.F. Kockum, Phys. Rev. Lett. 127, 140502 (2021).  DOI 10.1103/PhysRevLett.127.140502.  URL https://link.aps.org/doi/10.1103/PhysRevLett.127.140502
  * [5] W. Wang, H.K. Lo, Phys. Rev. A 100, 062334 (2019).  DOI 10.1103/PhysRevA.100.062334.  URL https://link.aps.org/doi/10.1103/PhysRevA.100.062334
  * [6] M.Y. Niu, S. Boixo, V.N. Smelyanskiy, H. Neven, npj Quantum Information 5(1), 33 (2019).  DOI 10.1038/s41534-019-0141-3.  URL https://doi.org/10.1038/s41534-019-0141-3
  * [7] X.M. Zhang, Z. Wei, R. Asad, X.C. Yang, X. Wang, npj Quantum Information 5(1), 85 (2019)
  * [8] R. Porotti, D. Tamascelli, M. Restelli, E. Prati, Communications Physics 2(1), 61 (2019)
  * [9] M. Bukov, A.G.R. Day, D. Sels, P. Weinberg, A. Polkovnikov, P. Mehta, Phys. Rev. X 8, 031086 (2018).  DOI 10.1103/PhysRevX.8.031086.  URL https://link.aps.org/doi/10.1103/PhysRevX.8.031086
  * [10] Y. Ding, Y. Ban, J.D. Martín-Guerrero, E. Solano, J. Casanova, X. Chen, Phys. Rev. A 103, L040401 (2021).  DOI 10.1103/PhysRevA.103.L040401.  URL https://link.aps.org/doi/10.1103/PhysRevA.103.L040401
  * [11] C. Cîrstoiu, Z. Holmes, J. Iosue, L. Cincio, P.J. Coles, A. Sornborger, npj Quantum Information 6(1), 82 (2020)
  * [12] J. Schuff, L.J. Fiderer, D. Braun, New Journal of Physics 22(3), 035001 (2020).  DOI 10.1088/1367-2630/ab6f1f.  URL https://doi.org/10.1088/1367-2630/ab6f1f
  * [13] S. Lohani, J.M. Lukens, R.T. Glasser, T.A. Searles, B.T. Kirby, arXiv e-prints arXiv:2201.09134 (2022)
  * [14] L. Gurvits, in _Proceedings of the Thirty-Fifth Annual ACM Symposium on Theory of Computing_ (Association for Computing Machinery, New York, NY, USA, 2003), STOC ’03, p. 10–19.  DOI 10.1145/780542.780545.  URL https://doi.org/10.1145/780542.780545
  * [15] A. Peres, Physical Review Letters 77(8), 1413 (1996)
  * [16] M. Horodecki, P. Horodecki, R. Horodecki, Physics Letters A 223(1-2), 1–8 (1996).  DOI 10.1016/s0375-9601(96)00706-2.  URL http://dx.doi.org/10.1016/S0375-9601(96)00706-2
  * [17] R. Horodecki, P. Horodecki, M. Horodecki, K. Horodecki, Rev. Mod. Phys. 81, 865 (2009).  DOI 10.1103/RevModPhys.81.865.  URL https://link.aps.org/doi/10.1103/RevModPhys.81.865
  * [18] A.C. Doherty, P.A. Parrilo, F.M. Spedalieri, Phys. Rev. Lett. 88, 187904 (2002).  DOI 10.1103/PhysRevLett.88.187904.  URL https://link.aps.org/doi/10.1103/PhysRevLett.88.187904
  * [19] M. Navascués, M. Owari, M.B. Plenio, Phys. Rev. A 80, 052306 (2009).  DOI 10.1103/PhysRevA.80.052306.  URL https://link.aps.org/doi/10.1103/PhysRevA.80.052306
  * [20] C. Harney, M. Paternostro, S. Pirandola, New Journal of Physics 23(6), 063033 (2021)
  * [21] A. Girardin, N. Brunner, T. Kriváchy, Physical Review Research 4(2), 023238 (2022)
  * [22] L. Breiman, Machine Learning 24(2), 123 (1996).  DOI 10.1007/BF00058655.  URL https://doi.org/10.1007/BF00058655
  * [23] R.N. Patro, S. Subudhi, P.K. Biswal, F. Dell’Acqua, International Journal of Remote Sensing 40(13), 4996 (2019)
  * [24] R.N. Patro, S. Subudhi, P.K. Biswal, F. Dell’Acqua, H.K. Sahoo, International Journal of Remote Sensing 40(24), 9279 (2019)
  * [25] S.B. Kotsiantis, I. Zaharakis, P. Pintelas, et al., Emerging artificial intelligence applications in computer engineering 160(1), 3 (2007)
  * [26] C. Cortes, V. Vapnik, Machine Learning 20(3), 273 (1995).  DOI 10.1007/BF00994018.  URL https://doi.org/10.1007/BF00994018
  * [27] L. Breiman, J.H. Friedman, R.A. Olshen, C.J. Stone, _Classification and Regression Trees_ (CRC Press, Boca Raton, 1984).  DOI 10.1201/9781315139470
  * [28] R.E. Schapire, _The Boosting Approach to Machine Learning: An Overview_ (Springer New York, New York, NY, 2003), pp. 149–171.  DOI 10.1007/978-0-387-21579-2˙9.  URL https://doi.org/10.1007/978-0-387-21579-2_9
  * [29] R.E. Schapire, in _Empirical inference_ (Springer, 2013), pp. 37–52
  * [30] N. Japkowicz, S. Stephen, Intelligent data analysis 6(5), 429 (2002)
  * [31] R. Akbani, S. Kwek, N. Japkowicz, in _European conference on machine learning_ (Springer, 2004), pp. 39–50
  * [32] Y. Tang, Y.Q. Zhang, N.V. Chawla, S. Krasser, IEEE Transactions on Systems, Man, and Cybernetics, Part B (Cybernetics) 39(1), 281 (2008)
  * [33] N.V. Chawla, K.W. Bowyer, L.O. Hall, W.P. Kegelmeyer, Journal of artificial intelligence research 16, 321 (2002)
  * [34] S. Subudhi, R.N. Patro, P.K. Biswal, in _Soft Computing for Problem Solving_ , ed. by J.C. Bansal, K.N. Das, A. Nagar, K. Deep, A.K. Ojha (Springer Singapore, Singapore, 2019), pp. 617–625
  * [35] C. Drummond, R.C. Holte, et al., in _Workshop on learning from imbalanced datasets II_ , vol. 11 (Citeseer, 2003), vol. 11, pp. 1–8
  * [36] C. Seiffert, T.M. Khoshgoftaar, J. Van Hulse, A. Napolitano, IEEE Transactions on Systems, Man, and Cybernetics-Part A: Systems and Humans 40(1), 185 (2009)
  * [37] QMLab: Global collaboration on quamtum machine learning (http://qmlab.org/) (2017)
  * [38] K. Życzkowski, Phys. Rev. A 60, 3496 (1999).  DOI 10.1103/PhysRevA.60.3496.  URL https://link.aps.org/doi/10.1103/PhysRevA.60.3496

##  Appendix A Feature vector

To illustrate what is feature vector $\bm{x}$, we consider the following
example. We know a quantum state ($\rho_{d}$) in $d$-dimensional Hilbert space
can be represented by a $d\times d$ density matrix using generalised Gell-Mann
matrices, $\sigma_{i}\in$ $SU(d)$ as

$\displaystyle\rho_{d}=\frac{1}{n}\left(\mathbb{I}+\sqrt{\frac{d(d-1)}{2}}\bm{x}.\bm{\sigma}\right),$
(3)

where $\bm{x}\in\mathbb{R}^{d^{2}-1}$ is the feature vector which satisfies
$x_{i}=\sqrt{\frac{d}{2(d-1)}}{\rm Tr}[\rho_{d}\sigma_{i}]$. This is possible
as $\rho$ is Hermitian and has trace unity.

In our analysis, we consider quantum systems in $d_{A}\otimes d_{B}$
dimensional Hilbert space $\mathcal{H}_{A}\otimes\mathcal{H}_{B}$ which are
represented by $d_{A}d_{B}\times d_{A}d_{B}$ density matrices. Hence, to
represent using feature vectors, we need Gell-Mann matrices $\sigma_{i}\in
SU(d_{A}d_{B})$, i.e., the $\bm{x}\in\mathbb{R}^{d_{A}^{2}d_{B}^{2}-1}$.

##  Appendix B Generating random density matrices in the code

Most of the contents in the appendix are elaborately discussed in Ref.[1]. We
will discuss the methods of producing random density matrices for specific
dimensions in a nutshell.

To produce random bipartite density matrices of any rank numerically, we use
the probability distribution $p(\mu,\theta,d)=\mu\times\triangle_{\theta}$,
where $\mu$ is the uniform distribution on $U(d)$ according to the Haar
measure, $\triangle_{\theta}$ is the Dirichlet distribution

$\displaystyle\triangle_{\theta}(\ell_{1},\cdots,\ell_{d}):=C_{\theta}\prod_{i=1}^{d}\ell_{i}^{-\theta}$
(4)

defined on the simplex $\sum_{i}^{d}\ell_{i}=1$, where $\theta>0$ is a
parameter and $C_{\theta}$ is a normalization constant. We set
$\theta=\frac{1}{2}$ for sampling both the two-qubit and two qutrit states.

Note that our dataset is exactly the same as is used in Ref.[1]. The Ref.[1]
observed the following trends during training using the generated samples:

  * •

For the two-qubit case, approximately 7% of the states among $5\times 10^{4}$
are PPT, i.e., separable state.

  * •

Among fairly large samples (randomly generated) of two-qutrits, only 2.2% are
PPT. After rejecting all the states with negative partial transpose while
sampling as they are assumed entangled (prior information), the total
collected PPT states are a total of $2\times 10^{4}$ samples. Among PPT
states, at least 66.24% are found to be separable using CHA. However, note
that during the testing, NPT states are also included.

The authors in Ref.[1] observe that these trends are consistent with the
previously predicted ones in Ref.[38].

##  Appendix C List of Abbreviations

  * CHA

Convex Hull Approximation

  * BCHA

Bagging based CHA

  * RUSBCHA

Random Under Sampling BCHA

  * ML

Machine Learning

  * PPT

Positive Partial Transpose

  * SVM

Support Vector Machine

  * SMOTE

Synthetic Minority Oversampling Technique

  * TP

True Positive

  * TN

True Negative

  * FP

False Positive

  * FN

False Negative

  * OA

Overall Accuracy

  * AA

Average Accuracy

  * OE

Overall Error

  * AE

Average Error