Next Article in Journal
Minimization of Active Power Loss Using Enhanced Particle Swarm Optimization
Next Article in Special Issue
VaR Estimation with Quantum Computing Noise Correction Using Neural Networks
Previous Article in Journal
An Improved Human-Inspired Algorithm for Distribution Network Stochastic Reconfiguration Using a Multi-Objective Intelligent Framework and Unscented Transformation
Previous Article in Special Issue
Quantum Computing Meets Deep Learning: A Promising Approach for Diabetic Retinopathy Classification
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Variational Quantum Circuit Topology Grid Search for Hypocalcemia Following Thyroid Surgery

by
Jose L. Salmeron
1,2,*,† and
Isabel Fernández-Palop
3,†
1
School of Engineering, CUNEF Universidad, 28040 Madrid, Spain
2
School of Engineering, Universidad Autónoma de Chile, Talca 1670, Chile
3
Escuela de Doctorado, Universidad Católica de Valencia San Vicente Mártir, 46001 Valencia, Spain
*
Author to whom correspondence should be addressed.
These authors contributed equally to this work.
Mathematics 2023, 11(17), 3659; https://doi.org/10.3390/math11173659
Submission received: 8 August 2023 / Revised: 20 August 2023 / Accepted: 23 August 2023 / Published: 24 August 2023
(This article belongs to the Special Issue Quantum Computing for Industrial Applications)

Abstract

:
Quantum computing’s potential to revolutionise medical applications has spurred interest in leveraging quantum algorithms for healthcare challenges. In this research, the authors explored the application of variational quantum circuits to predicting hypocalcemia risk following thyroid surgery. Hypocalcemia, resulting from hypoparathyroidism, is a common post-surgical complication. This novel approach includes a topology grid search of the variational quantum circuits. To execute the grid search, our research employed a classical optimiser that guided the adjustment of different circuit topologies, assessing their impact on predictive performance. Our research used, as relevant features, an intra-operative PTH (parathyroid hormone) at 10 min post-removal and percentage decrease of pre-operative and intra-operative PTH levels. The findings revealed insights into the interplay between variational quantum circuit topologies and predictive accuracy for hypocalcemia risk assessment.

1. Introduction

This paper addresses the classification problem of hypocalcemia resulting from hypoparathyroidism following thyroid surgery. The significance of the classification problem related to hypocalcemia resulting from hypoparathyroidism following thyroid surgery lies in its clinical implications and patient outcomes [1]. There are several important reasons for understanding and effectively classifying this condition:
  • Patient Care and Management: Hypocalcemia due to hypoparathyroidism is a potential complication of thyroid surgery. Accurate classification helps healthcare providers identify patients at risk, enabling timely interventions, monitoring, and personalised treatment plans.
  • Early Detection: A robust classification model can assist in early detection of hypocalcemia. Early intervention can prevent severe symptoms, improve patient recovery, and reduce hospitalisation durations.
  • Customised Treatment: Different patients may require varying levels of medical attention and calcium supplementation. Proper classification facilitates the tailoring of treatment strategies to individual patient needs, enhancing overall care quality.
  • Resource Allocation: Hospitals and medical facilities can allocate resources more effectively if they have a clear understanding of the likelihood and severity of post-thyroid surgery complications like hypocalcemia. This includes allocating medical staff, medications, and specialised equipment.
  • Research and Medical Knowledge: Assisting in resolving the classification problem yields insights that contribute to advancements in medical research [2]. Analysing patterns in patient data can lead to a better understanding of risk factors, predictive indicators, and potential preventive measures.
  • Reducing Costs: Accurately classifying patients can lead to optimised healthcare resource utilisation, potentially reducing unnecessary procedures, tests, and hospital stays, which can lower healthcare costs overall.
  • Patient Education: Proper classification can aid in patient education. Informed patients can better understand their condition, follow recommended guidelines, and engage in self-care practices that contribute to their well-being.
  • Quality of Life: Effective classification and management contribute to improved quality of life for patients who have undergone thyroid surgery. It can help prevent or minimise complications that might negatively impact daily life and activities.
As a result, the classification problem of hypocalcemia resulting from hypoparathyroidism after thyroid surgery is important, because it directly affects patient outcomes, healthcare resource allocation, medical research, and overall healthcare costs [3]. Proper classification enhances patient care and contributes to better treatment strategies, ultimately leading to improved patient well-being. For these reasons, the authors consider this to be a relevant effort.
From the technical point of view, quantum computing is a pioneering domain built upon the principles of quantum mechanics. Quantum computing has garnered significant attention in recent times, owing to its potential to completely transform various industries [4,5,6]. Diverging from classical computing, which employs bits to symbolise information as either 0 or 1, quantum computing applies qubits that can concurrently inhabit multiple states. This remarkable ability is made possible by the phenomena of superposition and entanglement. This distinctive attribute enables quantum computers to execute complex calculations at an exponentially accelerated pace compared to traditional computers [7,8]. This opens doors to resolving challenges that were previously deemed insoluble.
The contribution of this paper is twofold:
  • From a medical perspective, this paper demonstrates that hypocalcemia resulting from hypoparathyroidism following thyroid surgery can be predicted accurately, using parathyroid hormone levels.
  • From a quantum standpoint, this paper analyses the impact of repetition numbers for feature maps and real amplitudes on accuracy, exploring insights for the design of variational quantum circuits.
The remainder of the paper is organised as follow: Section 2 explains the medical perspectives about the research, Section 3 shows the theoretical background about the quantum machine learning approach, Section 4 details the experimental approach, and Section 5 shows the conclusions of the research.

2. Medical Perspectives about Hypocalcemia

Hypocalcemia due to hypoparathyroidism remains the most frequent complication encountered after thyroid surgery, leading to increased morbidity and hospital stay.
Transient hypoparathyroidism (duration less than 6 months) occurs in up to 20% of cases [9,10], whereas permanent hypoparathyroidism (duration longer than 6 months) occurs in approximately 0.8% to 3% of patients undergoing total thyroidectomy [9,10,11].
Numerous risk factors related to the development of this complication have been described in the literature, including the extent of the surgery, multiple re-interventions, cervical lymphadenectomy, thyroidectomy for Graves’ disease or thyroid carcinoma, ligature of the inferior thyroid artery at its trunk, the number of identified and preserved parathyroid glands during the operation, and the surgeon’s experience [12].
Parathyroid hormone (PTH) is the main regulator of calcium homeostasis. If PTH levels are altered after surgery, it can lead to a decrease in serum calcium below the lower limit of normal (<8.5 mg/dL or <4.2 mg/dL for ionised calcium), which may have clinical repercussions for the patient.
The parathyroid glands are responsible for the production of this hormone: given their anatomical proximity to the thyroid, the most significant causal factors in post-surgery hypocalcemia are trauma, devascularisation, or inadvertent removal of the parathyroid glands during thyroidectomy.
However, what is particularly concerning for the surgeon is that preserving the parathyroid glands through careful surgical technique does not completely exclude the possibility of developing this complication. Analytical hypocalcemia is referred to, such as a decrease in total serum calcium levels below 8.5 mg/dL or a decrease in the ionised calcium fraction below 4.2 mg/dL. Depending on the calcium level and the speed of its onset, hypocalcemia can manifest as acute or chronic. In chronic forms, osteomalacia, rickets, basal ganglia calcification with extrapyramidal symptoms, cataracts, soft tissue calcification, etc., are predominant.
In acute forms, most symptoms are due to muscular hyper-excitability. Symptoms may include paresthesias, cramps and spasms, hyper-reflexia, latent tetany (Chvostek’s and Trousseau’s signs), and, in severe cases, opisthotonus, bronchospasm, seizures, and cardiovascular abnormalities, among others. Normally, hypocalcemia does not occur until 24–48 h after a thyroidectomy, and the isolated determination of calcium would be most reliable after 72 h.
There are several strategies, described in the literature, for diagnosing and treating hypocalcemia. The most common method involves serially measuring calcium levels for 48 h, which delays diagnosis and requires longer hospital care. Another option is routine postoperative treatment for hypocalcemia, which will reduce hospital stay, but may result in the patient being overtreated, leading to potential complications.
It is essential to identify early those patients who will require calcium and vitamin D replacement therapy, so that treatment can be administered as early and as accurately as possible. Similarly, some patients can be safely discharged a few hours after surgery. Taking into account the decrease in PTH levels that occurs within minutes of the excision of a parathyroid adenoma, some studies have validated the role of postoperative PTH determination in total thyroidectomy as a predictor of postoperative hypocalcemia [13,14].
Unlike calcium values, which remain stable for a long time, parathyroid hormone (PTH) has a short half-life, so that the decrease in the amount of PTH released into the plasma results in a rapid decrease in circulating PTH (the nadir of PTH is reached between 4 and 6 h). However, there is no consensus on the optimal time for postoperative PTH determination or the PTH levels that would most accurately predict hypocalcemia. The most frequent complication after thyroid surgery is hypocalcemia as a consequence of postoperative hypoparathyroidism.
Despite the published studies on this subject, there are still unanswered questions, as there is no consensus on intraoperative PTH determination; it is not clear what the optimal time is for measurement nor what the levels are that will most accurately predict hypocalcemia. For this reason, the authors consider that this research is a worthy endeavour.

3. Theoretical Background

In this section, the authors delve into three key subjects that laid the groundwork for our research. The authors start by exploring the basics of quantum computing, providing insights into its fundamental principles. Following this, the authors analyse variational quantum circuits, breaking down their structure and functions as versatile tools in quantum computation. Finally, the authors examine the training processes of variational quantum classifiers, revealing the techniques that empower these classifiers to uncover intricate patterns and enhance quantum-assisted machine learning.

3.1. Quantum Computing Basics

A qubit (quantum bit) is the minimal information unit within the quantum computing field [15]. It is characterised as a two-dimensional Hilbert space housing two orthogonal bases denoted as |0〉 and 1〉, recognised as computational bases within two-level quantum computing. These bases are commonly depicted as follows: | 0 = [ 1 , 0 ] and | 1 = [ 0 , 1 ] . The state of a qubit can be represented as the sum of two computational bases, each multiplied by complex amplitudes. This characteristic arises from the unique property of qubits, known as superposition:
| ψ = α | 0 + β | 1 = α β ,
where { α , β } C . Note that α 2 and β 2 are the probabilities of obtaining the states | 0 and | 1 , respectively, and that α 2 + β 2 = 1 .
A single qubit can be represented by the Bloch sphere. In this representation, the north pole of the sphere corresponds to the state |0〉 (spin up or down in spin notation) (Figure 1a), and the south pole corresponds to the state |1〉 (spin down or up) (Figure 1b). Superposed states (Figure 1c) and any linear combination of |0〉 and |1〉 are situated at other points on the sphere, while the equatorial circumference represents states in uniform superposition.
Each pristine state of a qubit has the potential to be correlated to a unique location on the exterior of the Bloch sphere, while amalgamated states align with points within the sphere. The qubit’s condition on the Bloch sphere can be described using two tangible parameters, θ and ϕ , as follows:
| ψ = cos θ 2 | 0 + e i ϕ sin θ 2 | 1 ,
where ϕ [ 0 , π ] and ϕ [ 0 , 2 π ] , and where the global phase ϕ can be any value.
Quantum measurement entails extracting numerical data from a qubit. This yields a measurement outcome of + 1 for the |0〉 state and 1 for the |1〉 state, following a predetermined probability distribution linked to the quantum state. Consequently, multiple measurements are necessary, to ascertain the precise quantum state. The ultimate outcome of quantum measurement represents the anticipated value derived from all potential results.
Observables provide insights into quantum system properties and are subject to measurement. In a more formal way, observables are represented by Hermitian operators, preserving the mapping of Hilbert space onto itself. In the context of valid observables, their eigenvalues manifest as real numbers, serving as potential measurement outcomes. Additionally, observables can constitute an orthonormal basis within the designated Hilbert space, determining the state of the quantum system post-measurement. One of the more popular observables are the Pauli matrices. These Hermitian, involutory, and unitary matrices are three complex matrices with 2 × 2 dimensions:
σ x = 0 1 1 0 σ y = 0 i i 0 σ z = 1 0 0 1 .
These Pauli matrices form the basis for a complex two-dimensional Hilbert space, which corresponds to a qubit. Projection measurement entails extracting quantum information through operations performed on the observable and the density matrix of the quantum state under consideration, as follows [16]:
σ = Tr ( σ | ψ ψ | ) ,
where | ψ ψ | generates the density matrix.

3.2. Variational Quantum Circuits

Hybrid quantum–classical algorithms encompass scenarios where a classical algorithm optimises a parameterised quantum circuit, for the purpose of addressing a particular problem. These algorithms are also referred to as variational quantum algorithms (VQAs). VQAs [17] exhibit great potential for addressing a diverse array of problems. These include tasks like tackling combinatorial optimisation problems through the quantum approximate optimisation algorithm (QAOA) [18], determining the ground state of a provided Hamiltonian, using the variational quantum eigensolver (VQE) [19], or addressing classification issues utilising quantum neural networks.
Variational quantum algorithms prove to be well-suited to the constraints of noisy intermediate-scale quantum (NISQ) [4] hardware, as they can be executed with a limited number of layers and gates, making them particularly applicable to straightforward tasks. NISQ is a class of quantum computing systems that are characterised by their intermediate number of qubits and their susceptibility to noise and errors during quantum operations. The term "noisy" implies the presence of errors and imperfections in the quantum operations, due to factors such as decoherence, thermal fluctuations, and control imprecision. These errors are particularly pronounced in NISQ devices, due to their limited qubit coherence times and the challenges associated with error correction.
Variational quantum algorithms leverage an interactive loop connecting a classical computer and a quantum device. The former manages the adjustment of ansatz parameters, guided by the measurement outcomes derived from the quantum hardware. This iterative process continues until convergence is achieved. The main reasons for using classical optimisers include [20]:
  • Quantum Hardware Constraints: Quantum hardware currently faces limitations, in terms of qubit count, connectivity, and noise. As a result, training quantum circuits on real hardware can be challenging. Using classical optimisers to train VQCs can help in mitigating these hardware constraints.
  • Gradients and Derivatives: Variational quantum circuits involve complex parameter spaces that are often non-convex and non-linear. Calculating gradients or derivatives directly on quantum hardware can be intricate, due to the quantum nature of the operations. Classical optimisers, equipped with gradient-based techniques, can navigate these high-dimensional spaces more effectively.
  • Hyperparameter tuning: VQCs typically involve various hyperparameters, such as learning rates, initialisation strategies, and convergence criteria. Classical optimisers provide a systematic way to search and tune these hyperparameters, to achieve optimal performance.
  • Robustness: Quantum devices are prone to noise and decoherence, leading to errors in computations. Classical optimisers can offer more robust training processes, by accommodating and mitigating the impact of quantum errors.
  • Hybrid Approaches: Combining classical and quantum resources in hybrid algorithms can leverage the strengths of both paradigms. Classical optimisers can work alongside quantum circuits, enabling the development of hybrid quantum–classical algorithms that incorporate the advantages of both realms.
Classical optimisation techniques utilise insights into the parametric ansatz’s cost landscape, to pinpoint its minimum. The parameter updates guide the ansatz towards lower points on this cost surface. Across a broad spectrum of ansatz configurations, the cost landscape experiences a flattening effect as the qubit count increases [21]. Consequently, the task of optimisation becomes exponentially more challenging for the optimiser. This flattening phenomenon was initially identified through the analysis of gradient distributions across the parameter space, leading to the designation of the issue as “barren plateaus”. A variational quantum algorithm is said to encounter a barren plateau when its gradients decay exponentially, concerning specific hyperparameters, such as the number of qubits or layers.
Equation (5) represents the function f θ ( · ) , which is defined as the expectation value obtained from the quantum state | ψ ( x , θ ) under the action of the operator M. This equation encapsulates how quantum properties are linked to computational tasks involving observables and quantum states. In this sense, f θ ( · ) captures a specific property or characteristic of interest in a quantum computing context. The bra vector ψ ( x , θ ) | is the conjugate transpose of the ket vector | ψ ( x , θ ) and denotes the complex conjugate of the quantum state associated with the input x and the parameter θ . The operator M, often called the observable or measurement operator, corresponds to the physical quantity to observe within the quantum system. The ket vector | ψ ( x , θ ) models the quantum state associated with the input x and the parameter θ . The expression ψ ( x , θ ) | M | ψ ( x , θ ) computes the expectation value of the observable M when measured in the quantum state | ψ ( x , θ ) . This expression quantifies the average value that would be obtained if the measurement of M were performed many times on the state | ψ ( x , θ ) :
f θ ( x ) = | x | ψ ( x , θ ) | 2 = ψ ( x , θ ) | M | ψ ( x , θ ) .
To build a quantum circuit model as a VQC (Figure 2), the authors employed the quantum circuit denoted as U ( x , θ ) , contingent upon both the input x and the parameters θ , to act upon the initial state | 0 = | 00 0 , resulting in the produced output | ψ ( x , θ ) | . Subsequently, it was viable to use either the probabilities associated with the output states |x〉 or the anticipated value of a measurement observable M as the model’s output.
In this sense, ansatz topology is critical to the performance of the VQC. “Ansatz topology” refers to the specific structure of the quantum circuit that constitutes the ansatz in a variational quantum algorithm. The topology of the ansatz refers to the arrangement of gates, qubits, and their connections within the circuit. The choice of ansatz topology can significantly impact the algorithm’s performance, efficiency, and convergence. Different problems may require different ansatz topologies, to capture the underlying quantum behaviour accurately. There exists no explicit convention regarding the internal architecture of the ansatz, allowing U ( x , θ ) to encompass a wide array of possibilities—even nothing. Frequently, a common approach involves selecting a structure composed of multiple layers, contingent upon the input x [22,23,24,25].

3.3. Training a Variational Quantum Classifier

Classification stands as a fundamental task for machine learning across various domains, rendering QML-based classifiers a topic of notable attention.
The process of training VQCs entails identifying an optimal parameter set θ (comprising θ 1 , θ 2 , , θ n ) that minimises a problem-specific cost function. In the case of a variational quantum classifier, the problem is the classification of a number of instances in the labelled classes. Let us contemplate a cost function (Equation (6)) denoted as C ( θ ) that relies on a model f ( · ) , itself contingent upon parameters θ :
C ( θ ) = E [ y f ( x ; θ ) ] k .
Applying the chain rule, the partial derivative of C with respect to a parameter γ θ belonging to the set θ can be expressed as follows:
γ C ( θ ) = C f θ f θ γ ,
where C can be computed classically, using the chain rule.

4. Experimental Approach

There exist four distinct strategies for integrating quantum computing and machine learning, categorised based on the nature of the data—classical (C) or quantum (Q)—and the computational platform—classical (C) or quantum (Q). This research focused on classical data (C) and quantum algorithms (Q). In the following sections, the authors describe the data and our experimental approach.

4.1. Data Gathering

The inclusion criteria were patients over 18 years of age who were going to undergo thyroid surgery (hemithyroidectomy or total thyroidectomy), regardless of the initial diagnosis, and who had signed an informed consent to participate in the study. The exclusion criteria were: (a) patients with co-existing renal or parathyroid pathology; (b) patients with serum intact parathyroid hormone levels outside the normal range in the pre-operative stage.
Whether the patients underwent hemithyroidectomy or total thyroidectomy, the surgical technique used was the usual one for these types of interventions. A transverse cervicotomy was performed, and the thyroid lobe was accessed through the midline, after creating flaps beneath the platysma muscle. If possible, the prethyroid muscles (sternothyroid and sternohyoid) were not sectioned. An extracapsular dissection was performed with control of the vascular pedicles, before the resection of the thyroid parenchyma. The parathyroid glands were meticulously identified and preserved. Both recurrent laryngeal nerves were recognised, to avoid injury during surgery.
The features were refined to a limited subset, for the context of this investigation. The primary feature, specifically, was the intra-operative PTH measured at 10 min post specimen removal. This feature entailed the assessment of intact parathyroid hormone levels in the bloodstream 10 min subsequent to surgical specimen removal. The secondary feature encompassed the percentage reduction of pre-operative and intra-operative PTH, calculated as the proportional decrease in PTH values between the pre-operative measurement and immediately post-surgery.
The central objective revolved around forecasting the calcium levels on the day following the surgery. The identification of hypocalcemia was based on whether the target value fell below 4.2.
Figure 3 shows the pairwise relationships in the dataset. It can be observed that the distributions of both features overlapped within a specific region. Additionally, it was verified that instances with low values of both variables are more challenging to distinguish.
The dataset’s main statistics are shown in Table 1. There were 234 samples (instances) in the dataset (75% training dataset and 25% validation dataset). The dataset was perfectly balanced, as there were the same number of samples in each class. The features were not normalised, and their value ranges were different. Therefore, transforming the features to the same scale would be helpful.

4.2. Experiment Design

The authors proceeded to train a VQC as a classifier within Qiskit machine learning principles. This VQC embodied two pivotal components: a feature map and an ansatz. The dataset was composed of classical data. To convert the data into qubits, a data encoding was needed. The data encoding process was handled by a feature map. While feature mapping is a prevalent mechanism within machine learning, the action of loading data into quantum states remains exclusive to the quantum realm, being absent from classical machine learning, which exclusively operates within the classical domain.
Upon the completion of data loading, the immediate utilisation of a parameterised quantum circuit became indispensable. This circuit is similar to the layers in conventional neural networks [26]. It encompasses an ensemble of trainable weights. The objective of fine-tuning the weights is to minimise an objective function, which quantifies the disparity between predictions and the labelled data (target). This parameterised quantum circuit is named “ansatz”.
For data encoding, the authors applied a feature map. Specifically, a second-order Pauli-Z evolution circuit, which is a quantum circuit designed to implement unitary transformations based on second-order Pauli-Z operators. These operators are part of the Pauli group, which consists of the identity operator (I) and three Pauli matrices: Pauli-X ( σ x ), Pauli-Y ( σ y ), and Pauli-Z ( σ z ). In the context of quantum computing, the Pauli-Z operator ( σ z ) is represented as a diagonal matrix that contains the eigenvalues +1 and −1 on its diagonal. The second-order Pauli-Z operators are products of two Pauli-Z matrices acting on different qubits. For example, if we have a multi-qubit system, a second-order Pauli-Z operator could be something like σ z σ z , where ⊗ represents the tensor product. The second-order Pauli-Z evolution circuit utilises these operators, to apply unitary transformations to a quantum state.
The chosen feature map possessed a dimension of 2, reflecting the count of features. An essential parameter was the degree of freedom represented by the quantity of iterated circuits (with a minimum value of 1). In this study, the authors delved into determining the optimal count of repeated circuits for the given classification tasks. Figure 4 depicts the second-order Pauli-Z evolution circuit (feature map) with 1, 2, and n repetitions. The repetitions are illustrated using circuit blocks. The repetition of the circuit block constituted one of the elements under analysis in this research.
Another element related to the topology of the circuit is the repetition of the real amplitudes. The real amplitudes refer to the probability amplitudes in a quantum system that are constrained to be real numbers rather than complex numbers. In a quantum system, probability amplitudes describe the likelihood of a quantum particle or system being in a specific state after measurement.
The real amplitudes circuit serves as a heuristic trial wave function employed as an ansatz in both classification circuits within quantum machine learning. This circuit is structured with interleaved layers of rotations and entanglements. The configuration of entanglement can either be defined by the user or chosen from a predefined collection. The frequency of repetition indicates the number of times the sequence comprising a rotation layer followed by an entanglement layer is duplicated.
Figure 5 represents three real amplitudes circuits with 1, 2, and n repetitions. The circuits comprise alternating layers of rotations and entanglements. The entanglement pattern can be user-defined or selected from a predefined set. The term “real amplitudes” refers to the fact that the prepared quantum states possess solely real amplitudes; the complex part is consistently set to 0. The alternating layers can be repeated, representing another element analysed in this paper.
In this research, the topology of a variational quantum circuit was examined, with a focus on the repetitions of the feature maps and real amplitudes. To narrow the investigation, repetitions ranging from 1 to 6 times were analysed. The applied optimiser to train the VQC was simultaneous perturbation stochastic approximation (SPSA). SPSA is a gradient descent technique employed for optimising systems characterised by multiple unspecified parameters. The main attribute of SPSA lies in its stochastic gradient approximation, demanding a mere two objective function measurements, irrespective of the optimisation problem’s dimensionality.

4.3. Results

Following the experiments, the authors numerically investigated the performance of our VQC model with different topologies and compared them. The grid search was conducted with repetitions from 1 to 6, both in the feature map and real amplitudes. The metric used was accuracy. The obtained results are shown in Table 2.
The best accuracy in the validation stage was achieved by a variational quantum circuit with 2 repetitions of the feature map and 4 repetitions of the real amplitudes ansatz. On the other hand, the worst accuracy in the same stage was achieved by a VQC with 5 repetitions of the feature map and 3 repetitions of the real amplitudes ansatz.
The table was split into five groups, for the sake of understanding. The first group obtained higher accuracy during the validation stage, while the last one had lower results. In general, a lower number of repetitions of the feature maps led to higher accuracy in both the training and validation stages, while a higher number resulted in lower accuracy in both stages. Figure 6 displays the visualisation of the optimal topology for the feature map (2 repetitions) and real amplitudes (4 repetitions) in this use case.

4.4. Discussion

In this research, the authors analysed the impact of the topology of the second-order Pauli-Z evolution circuit and real amplitudes on the accuracy of a VQC. The proposal was validated by a use case involving the prediction of hypocalcemia risk following thyroid surgery. This research constituted an exploration into the training of VQC parameters. In this sense, the results provide insights into the topological design relevance of VQCs.
Note that it can be highlighted that excessively large circuits do not yield better outcomes than shallow circuits in the presented use case. As for the number of repetitions of real amplitudes, there is no clear rule, as different numbers can be observed across Table 2. These insights are also confirmed by Table 3, which shows the correlations between the number of repetitions and accuracy for both cases. The correlations between the number of feature map repetitions and both accuracies were highly negative, suggesting that a lower number leads to higher accuracy. On the other hand, the correlations between the number of real amplitudes repetitions and both accuracies were close to zero in both cases, indicating that this variable was not highly relevant in this experiment.
Table 4 illustrates the correlation between the number of feature map repetitions and accuracy. The correlation weakens notably when considering feature map repetitions higher than 3. This weakened correlation indicates that feature maps with more than 3 repetitions might not necessarily result in improved accuracy and could even lead to diminished performance.
Table 5 depicts the correlation between the number of real amplitudes repetitions and accuracy. The correlation approaches zero when considering real amplitudes repetitions higher than 3. This suggests that real amplitudes repetitions with more than 3 repetitions (in fact, with any repetition number) do not lead to improved accuracy.

5. Conclusions

In conclusion, our analysis of the impact of repetition numbers for feature maps and real amplitudes on accuracy yielded valuable insights. Generally, a reduced number of feature map repetitions led to heightened accuracy in both training and validation stages, while an increased number tended to result in diminished accuracy across these stages. However, the situation was less straightforward when considering the repetition of real amplitudes, as varying numbers were observed throughout the dataset.
These findings are substantiated by the correlations presented in Table 3, which illuminate the relationships between repetition numbers and accuracy. Specifically, the strong negative correlation between feature map repetition numbers and accuracy indicates that fewer repetitions contribute to higher accuracy levels. Conversely, the near-zero correlation between real amplitudes repetitions numbers and accuracy suggests that this factor held minimal sway in our experimental context.
Overall, our study underscores the significance of thoughtful feature map repetition selection in optimising accuracy. Moreover, it emphasises the nuanced nature of real amplitudes repetitions effects, cautioning against assuming a linear relationship. These insights have valuable implications for enhancing the design and interpretation of similar experiments in the future.
In general terms, further research into the automated design of VQCs is required, and this will be the focus of our future research endeavours. This study has been limited to the second-order Pauli-Z evolution circuit and real amplitudes repetitions, but future research will need to incorporate an analysis of quantum gates in the design of these quantum circuits. Another area for future research could be to focus on investigating how to address cases where the accuracy trend does not follow a convex curve. An alternative approach might involve treating it as a non-convex surface, seeking the global optimum while avoiding local optima, much as evolutionary algorithms tackle similar challenges.

Author Contributions

Conceptualisation, J.L.S. and I.F.-P.; methodology, J.L.S. and I.F.-P.; software, J.L.S. and I.F.-P.; validation, J.L.S. and I.F.-P.; formal analysis, J.L.S. and I.F.-P.; investigation, J.L.S. and I.F.-P.; resources, J.L.S. and I.F.-P.; data curation, J.L.S. and I.F.-P.; writing—original draft preparation, J.L.S. and I.F.-P.; writing—review and editing, J.L.S. and I.F.-P.; visualisation, J.L.S. and I.F.-P. All authors have read and agreed to the published version of the manuscript.

Funding

This research received no external funding.

Informed Consent Statement

The present study was approved by the Ethics and Clinical Research Committee of Sagunto Hospital, as it complied with the required ethical and methodological standards. There were no additional risks to the patients’ health, as their inclusion in the study did not involve any variation in the usual diagnostic and therapeutic procedures for post-surgical hypoparathyroidism. Moreover, there was no violation of their data privacy. The data were collected and safeguarded by the Hospital staff, maintaining confidentiality throughout the process. All patients were duly informed about the diagnostic tests and surgical intervention, and each of them provided informed consent.

Conflicts of Interest

The authors declare no conflict of interest.

Abbreviations

The following abbreviations are used in this manuscript:
COBYLAconstrained optimisation by linear approximation
GSLSGaussian-smoothed line search
L-BFGS-Blimited-memory BFGS-bound optimiser
NFTNakanishi–Fujii–Todo algorithm
PSOparticle swarm optimisation
PTHparathyroid hormone
QDPSOquantum discrete particle swarm optimisation
SPSAsimultaneous perturbation stochastic approximation
TNCtruncated Newton
VQCvariational quantum circuit

References

  1. Yazicioglu, M.A.; Yilmaz, A.; Kocaoz, S.; Ozçaglayan, R.; Parlak, O. Risks and prediction of postoperative hypoparathyroidism due to thyroid surgery. Sci. Rep. 2021, 11, 11876. [Google Scholar] [CrossRef] [PubMed]
  2. Salmeron, J.L.; Rahimi, S.A.; Navalie, A.M.; Sadeghpour, A. Medical Diagnosis of Rheumatoid Arthritis using Data driven PSO-FCM. Neurocomputing 2017, 232, 104–112. [Google Scholar] [CrossRef]
  3. Burger, F.; Fritsch, H.; Zwierzina, M.; Prommegger, R.; Konschake, M. Postoperative Hypoparathyroidism in Thyroid Surgery: Anatomic-Surgical Mapping of the Parathyroids and Implications for Thyroid Surgery. Sci. Rep. 2019, 9, 15700. [Google Scholar] [CrossRef] [PubMed]
  4. Preskill, J. Quantum computing in the NISQ era and beyond. Quantum 2018, 2, 1–20. [Google Scholar] [CrossRef]
  5. Rahimi, S.A.; Kolahdoozi, M.; Mitra, A.; Salmeron, J.L.; Navali, A.M.; Sadeghpour, A.; Mohammadi, A.M. Quantum-Inspired Interpretable AI-Empowered Decision Support System for Detection of Early-Stage Rheumatoid Arthritis in Primary Care using Scarce Dataset. Mathematics 2022, 10, 496. [Google Scholar] [CrossRef]
  6. Sun, J.; Feng, B.; Xuv, W.; Strasser, S.; Goodman, R.; Sheppard, J.; Butcher, S. Particle swarm optimization with particles having quantum behavior. In Proceedings of the 2004 Congress on Evolutionary Computation, Portland, OR, USA, 19–23 June 2004; pp. 325–331. [Google Scholar]
  7. Bermejo, F.; Orús, R. Variational quantum and quantum-inspired clustering. Sci. Rep. 2023, 13, 13284. [Google Scholar] [CrossRef] [PubMed]
  8. Patil, S.; Banerjee, S.; Panigrahi, P.K. Measurement-based quantum clustering algorithms. arXiv 2023, arXiv:2302.00566. [Google Scholar]
  9. Hundahl, S.A.; Cady, B.; Cunninham, M.P.; Mazzaferri, E.; McKee, R.F.; Rosai, J.; Shah, J.P.; Fremgen, A.M.; Stewart, A.K.; Hölzer, S. Initial results from a prospective cohort study of 5583 cases of thyroid carcinoma treated in the United States during 1966. U.S and German Thyroid Cancer Study Group. An American College of Surgeons Commission on Cancer Patient Care Evaluation study. Cancer 2000, 89, 202. [Google Scholar] [CrossRef]
  10. Flynn, M.B.; Lyons, K.J.; Tarter, J.W.; Ragsdale, T.L. Local complications after surgical resection for thyroid carcinoma. Am. J. Surg. 1994, 168, 404. [Google Scholar] [CrossRef]
  11. Richmond, B.K.; Eads, K.; Flaherty, S.; Belcher, M.; Runyon, D. Complications of thyroidectomy and parathyroidectomy in the rural community hospital setting. Am. Surg. 2007, 73, 332. [Google Scholar] [CrossRef]
  12. Edafe, O.; Antakia, R.; Laskar, N.; Uttley, L.; Balasubramanian, S.P. Systematic review and meta-analysis of predictors of post-thyroidectomy hypocalcaemia. Br. J. Surg. 2014, 101, 307–320. [Google Scholar] [CrossRef] [PubMed]
  13. Islam, M.S.; Sultana, T.; Paul, D.; Huq, A.H.; Chowdhury, A.A.; Ferdous, C.; Ahmed, A.N. Intraoperative serum parathyroid hormone level is an indicator of hypocalcaemia in total thyroidectomy patients. Bangladesh Med. Res. Counc. Bull. 2012, 38, 84–89. [Google Scholar] [CrossRef] [PubMed]
  14. Bozec, A.; Guevara, N.; Bailleux, S.; Castillo, L.; Santini, J. Early PTH assay after total thyroidectomy: Predictive factor for post operative hypocalcemia? Rev. Laryngol. Otol. Rhinol. (Bord.) 2006, 127, 141–144. [Google Scholar] [PubMed]
  15. Kilin, S.Y. Quantum optics and quantum information. Opt. Spectrosc. 2001, 91, 325–326. [Google Scholar] [CrossRef]
  16. Wu, J.; Hu, T.; Li, Q. Quantum optics and quantum information. arXiv 2023, arXiv:2307.111875v1. [Google Scholar]
  17. Cerezo, M.; Arrasmith, A.; Babbush, R.; Benjamin, S.C.; Endo, S.; Fujii, K.; McClean, J.R.; Mitarai, K.; Yuan, X.; Cincio, L.; et al. Variational quantum algorithms. Nat. Rev. Phys. 2021, 3, 625–644. [Google Scholar] [CrossRef]
  18. Farhi, E.; Goldstone, J.; Gutmann, S. A Quantum Approximate Optimization Algorithm. arXiv 2014, arXiv:1411.4028. [Google Scholar]
  19. Pesah, A.; Cerezo, M.; Wang, S.; Volkoff, T.; Sornborger, A.T.; Coles, P.J. Absence of Barren Plateaus in Quantum Convolutional Neural Networks. Phys. Rev. X 2021, 11, 041011. [Google Scholar] [CrossRef]
  20. Pellow-Jarman, A.; Sinayskiy, I.; Pillay, A.; Petruccione, F. A comparison of various classical optimizers for a variational quantum linear solver. Quantum Inf. Process. 2021, 20, 202. [Google Scholar] [CrossRef]
  21. McClean, J.R.; Boixo, S.; Smelyanskiy, V.N.; Babbush, R.; Neven, H. Barren plateaus in quantum neural network training landscapes. Nat. Commun. 2018, 9, 4812. [Google Scholar] [CrossRef]
  22. Li, G.; Ye, R.; Zhao, X.; Wang, X. Concentration of Data Encoding in Parameterized Quantum Circuits. In Proceedings of the NeurIPS 2022, Advances in Neural Information Processing Systems, New Orleans, LA, USA, 28 November–9 December 2022; Volume 35. [Google Scholar]
  23. Kennedy, J.; Eberhart, R.C. A discrete binary version of the particle swarm algorithm. In Proceedings of the IEEE International Conference on Systems, Man, and Cybernetics, Orlando, FL, USA, 12–15 October 1997; Volume 5, pp. 4104–4108. [Google Scholar]
  24. Schuld, M.; Petruccione, F. Machine Learning with Quantum Computers; Springer: Berlin/Heidelberg, Germany, 2022. [Google Scholar]
  25. Schuld, M.; Killoran, N. Quantum machine learning in feature hilbert spaces. Phys. Rev. Lett. 2019, 122, 040504. [Google Scholar] [CrossRef]
  26. Guerrero-Gomez-Olmedo, R.; Salmeron, J.L.; Kuchkovsky, C. LRP-Based path relevances for global explanation of deep architectures. Neurocomputing 2020, 381, 252–260. [Google Scholar] [CrossRef]
Figure 1. Geometric representation of the Bloch sphere: (a) state |0〉; (b) state |1〉; (c) superposition of states.
Figure 1. Geometric representation of the Bloch sphere: (a) state |0〉; (b) state |1〉; (c) superposition of states.
Mathematics 11 03659 g001
Figure 2. Variational Quantum Circuit.
Figure 2. Variational Quantum Circuit.
Mathematics 11 03659 g002
Figure 3. Pairwise relationships in the dataset.
Figure 3. Pairwise relationships in the dataset.
Mathematics 11 03659 g003
Figure 4. Second-order Pauli-Z evolution circuit with 1, 2, and n repetitions.
Figure 4. Second-order Pauli-Z evolution circuit with 1, 2, and n repetitions.
Mathematics 11 03659 g004
Figure 5. Real amplitudes circuits with 1, 2, and n repetitions.
Figure 5. Real amplitudes circuits with 1, 2, and n repetitions.
Mathematics 11 03659 g005
Figure 6. Best circuit’s design.
Figure 6. Best circuit’s design.
Mathematics 11 03659 g006
Table 1. Dataset descriptive statistics.
Table 1. Dataset descriptive statistics.
FeatureMeanstdminmax
Intra-operative PTH 10 min after removal23.6916.285.075.0
Percentage decrease of pre-operative and intra-operative PTH−0.550.29−0.880.40
Calcium next day 10.50.50.01.0
1 target.
Table 2. Results by accuracy (validation).
Table 2. Results by accuracy (validation).
Feature Map (reps)Real Amplitudes (reps)Accuracy (Train)Accuracy (Validation)
240.8114000.915300
220.8057000.898300
230.8171000.898300
250.8057000.881400
130.8114000.881400
140.8114000.881400
150.8114000.881400
120.8114000.881400
330.7657000.847500
210.8057000.847500
320.7657000.813600
310.7600000.796600
340.7714000.762700
350.7600000.762700
450.7143000.694900
430.7257000.694900
410.6857000.678000
440.7257000.678000
510.6914000.644100
110.6286000.644100
420.7143000.627100
550.6229000.559300
520.6286000.542400
540.6400000.542400
530.6457000.525400
Table 3. Features/accuracy correlation (whole dataset).
Table 3. Features/accuracy correlation (whole dataset).
Accuracy (Train)Accuracy (Validation)
Feature map (N)−0.7488−0.8347
Real amplitudes (N)0.13530.0786
Table 4. Features/accuracy correlation (feature map repetitions higher than 3).
Table 4. Features/accuracy correlation (feature map repetitions higher than 3).
Accuracy (Train)Accuracy (Validation)
Feature map (N)−0.0787−0.2599
Real amplitudes (N)0.0499−0.0846
Table 5. Features/accuracy correlation (real amplitudes repetitions higher than 3).
Table 5. Features/accuracy correlation (real amplitudes repetitions higher than 3).
Accuracy (Train)Accuracy (Validation)
Feature map (N)−0.3551−0.5571
Real amplitudes (N)−0.0452−0.0680
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Salmeron, J.L.; Fernández-Palop, I. Variational Quantum Circuit Topology Grid Search for Hypocalcemia Following Thyroid Surgery. Mathematics 2023, 11, 3659. https://doi.org/10.3390/math11173659

AMA Style

Salmeron JL, Fernández-Palop I. Variational Quantum Circuit Topology Grid Search for Hypocalcemia Following Thyroid Surgery. Mathematics. 2023; 11(17):3659. https://doi.org/10.3390/math11173659

Chicago/Turabian Style

Salmeron, Jose L., and Isabel Fernández-Palop. 2023. "Variational Quantum Circuit Topology Grid Search for Hypocalcemia Following Thyroid Surgery" Mathematics 11, no. 17: 3659. https://doi.org/10.3390/math11173659

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop