Artificial Intelligence-Assisted Loop Mediated Isothermal Amplification (AI-LAMP) for Rapid Detection of SARS-CoV-2

Until vaccines and effective therapeutics become available, the practical solution to transit safely out of the current coronavirus disease 19 (CoVID-19) lockdown may include the implementation of an effective testing, tracing and tracking system. However, this requires a reliable and clinically validated diagnostic platform for the sensitive and specific identification of SARS-CoV-2. Here, we report on the development of a de novo, high-resolution and comparative genomics guided reverse-transcribed loop-mediated isothermal amplification (LAMP) assay. To further enhance the assay performance and to remove any subjectivity associated with operator interpretation of results, we engineered a novel hand-held smart diagnostic device. The robust diagnostic device was further furnished with automated image acquisition and processing algorithms and the collated data was processed through artificial intelligence (AI) pipelines to further reduce the assay run time and the subjectivity of the colorimetric LAMP detection. This advanced AI algorithm-implemented LAMP (ai-LAMP) assay, targeting the RNA-dependent RNA polymerase gene, showed high analytical sensitivity and specificity for SARS-CoV-2. A total of ~200 coronavirus disease (CoVID-19)-suspected NHS patient samples were tested using the platform and it was shown to be reliable, highly specific and significantly more sensitive than the current gold standard qRT-PCR. Therefore, this system could provide an efficient and cost-effective platform to detect SARS-CoV-2 in resource-limited laboratories.

platform [22], we have developed an ultra-low-cost molecular diagnostic device with an integrated single-board computer, imaging camera, artificial intelligence-based image processing algorithm and mobile app.
In this study, we developed a high-resolution comparative genomics analysis-guided novel RT-LAMP assay for the specific and sensitive detection of SARS-CoV-2 in comparison to WHO recommended qRT-PCR assays. In order to provide a simple "sample-to-answer workflow", an ultra-low-cost and user-friendly diagnostic platform was engineered and further enhanced with a module for automated image acquisition and processing. Artificial intelligence-guided assessment of the LAMP assay provided faster detection of colour changes in the LAMP reaction, further enhancing the assay performance and thus reducing the potential for human error in results interpretation. Finally, the assay was validated on RNA extracted from clinical samples from SARS-CoV-2 suspected patients to demonstrate its real-life applicability.

Ethics Statement
This study was conducted in accordance with and approved by the Faculty of Health and Medicine Research Ethics Committee (FHMREC) of Lancaster University. The FHMREC has approved the research application on 8 June 2020 and is available under the reference number FHMREC19112. The study was exempt from requiring specific patient consent as it only involved the use of extracted RNA and existing collections of data or records that contained non-identifiable data about human patients.

In Silico Nucleotide Sequence Comparisons and Primer Design
To design specific LAMP primer sets for the detection of SARS-CoV-2, all available complete genome sequences were downloaded from GISAID Initiative (https://www.gisaid.org/), aligned and the conserved part was selected and used as the template of the LAMP primer design. To identify an efficient primer set, three sets of specific LAMP primers were hand-picked and validated using PrimerExplorer V5 software (http://primerexplorer.jp/elamp4.0.0/index.html). Primers were validated using online BLAST program (http://www.ncbi.nlm.gov/BLAST) to ensure their specificity.

Cloning and In Vitro Transcription of RdRP Target Gene
The coding sequence of SARS-CoV-2 RdRp gene was chemically synthesized and cloned into pVAX1 plasmid (Invitrogen, Carlsbad, CA, USA) between KpnI and NotI restriction sites. The plasmid was propagated in DH5α cells and purified using MiniPrep Qiagen Kits (Qiagen, Manchester, UK). The linearized plasmid with pVAX1-RdRP was used for in vitro transcription using the T7 RiboMAX™ Express Large-Scale RNA Production System (Promega, Madison, WI, USA). The copy number of in vitro transcribed RNA was calculated from RNA concentration measured with NanoDrop™ 2000c Spectrophotometers (Thermo-Fisher Scientific, Waltham, MA, USA) in triplicate. RNA products were then purified using the RNeasy MinElute Cleanup Kit (Qiagen, Valencia, CA, USA). A standard curve was generated using dilutions of the standard in vitro transcribed RNAs using SuperScript III Platinum One-Step qRT-PCR Kit as per the manufacturer's protocol (Invitrogen, Carlsbad, CA, USA) using the CFX96 Touch Real-Time PCR Detection System (BioRad Laboratories, Watford, UK).

Clinical Sample Processing and Spiking with miR-cel-miR-39-3p RNA
A total of 199 nasopharyngeal swabs were individually collected from CoVID-19 suspected patients through the routine NHS collection procedure for COVID-19 screening. These samples were stored and transported in the virus transport media (VTM) to the NHS diagnostic laboratory at Lancaster University, UK. All samples were individually spiked with 50 pmol/L of synthesized Caenorhabditis elegans miR-cel-miR-39-3p (Thermo-Fisher Scientific, Waltham, MA, USA). The miR-cel-miR-39-3p RNA lacked any sequence homology to the human or viral gene and thus presents an ideal RNA extraction control. Total RNA including miRNAs was extracted using 140 µL of the spiked-VTM by the commercial QIAamp Viral RNA Mini kit (Qiagen, Valencia, CA, USA). The miR-cel-miR-39-3p RNA was used to serve as an internal control to monitor extraction efficiency and was used for data normalization. The final RNA yield and purity were determined by the A260/A280 ratio measured by a NanoDrop ND-1000 spectrophotometer (NanoDrop Technologies/Thermo-Fisher Scientific, Waltham, MA, USA) with a ratio of 1.80 to 2.00, which is indicative of good RNA purity. The isolated RNA was stored at −80 • C for further use.

Real-Time Fluorescent-Based Quantitative PCR
Suspected SARS-CoV-2 clinical samples were tested for positivity by qRT-PCR. Briefly, RNA was extracted from Viral Transport Media using the QIAamp Viral RNA Mini kit (Qiagen, Valencia, CA, USA) following the manufacturer's instructions. The qRT-PCR was conducted using the SuperScript III Platinum One-Step qRT-PCR Kit as per the manufacturer's protocol (Invitrogen Carlsbad, CA, USA) in the CFX96 Touch Real-Time PCR Detection System (BioRad Laboratories, Watford, UK), according to the cycling protocol. The reaction was performed using the specific primer set RdRpF, RdRpR and FAM-labelled probe or NP-F and NP-R and ROX labelled probes designed to detect SARS-CoV2. The 25-µL PCR reaction consists of 12.5 µL 2X Reaction Mix, 0.2 µM of each primer and 0.1 µM probe, 0.5 µL of SuperScript ® III RT/Platinum ® Taq Mix, 5 µL of RNA sample and nuclear free water. The cycling program was performed in the CFX96 Touch Real-Time PCR Detection System (Applied Biosystems, Madison, WI, USA), according to the cycling protocol. The amount of viral RNA in each sample was estimated by comparing the cycle threshold values (Ct) to the standard curve made by 10-fold dilutions of previously titrated in vitro transcribed RdRP gene.

AI-LAMP Assay Performance
All experiments for LAMP assay were run in triplicate. The LAMP reactions were performed using WarmStart TM Colorimetric LAMP 2X Master Mix (New England Biolabs, Hitchin, UK). A 10X primer mix (FIP, 16 µM; BIP, 16 µM; F3, 2 µM; B3, 2 µM; LF, 4 µM; LB, 4 µM) was prepared. A 25 µL reaction mixture (12.5 µL 2X MasterMix; 2.5 µL 10X primer mix; 2.5 µL RNA and 7.5 µL DNase & RNase-free molecular grade water) was mixed homogeneously and centrifuged. The LAMP assays were performed in a thermocycler (MJResearch) at 65 • C for 30 min or in the engineered device. Colour change was observed directly by the naked eye or through AI image processing and agarose gel electrophoresis was performed to confirm the results. The completion of amplification was indicated by the colour in the tube, wherein yellow was considered positive and pink was regarded as negative. All amplicons were confirmed by 2% agarose gel electrophoresis.

Artificial Intelligence Based Test-Tube Colour Detection
A loop-mediated isothermal amplification (LAMP) assay based COVID-19 test device was developed to capture the COVID-19 test results in 30 min, based on colour changes. Artificial intelligence (AI) based colour detection was proposed to identify colour changes considering different lighting issues and to reduce the test running time to less than 30 min. Images were acquired from the COVID-19 test kit, which carried 8 test-tubes including NTC (negative test control) and PTC (positive test control) for every 20 s during the test operation. Each image was cropped into separate tubes using the template matching approach and labelled manually based on their colour.

Analytical Specificity and Sensitivity of the LAMP Assay
The designed RdRp primer sets for LAMP to detect SARS-CoV-2 were validated for their specificity by testing the cross-reactivity with other viruses, including influenza a virus, Vesicular stomatitis virus (VSV), Sendai virus (SeD), infectious bronchitis virus (IBV) and Newcastle disease virus (NDV). Likewise, the developed LAMP assay was evaluated to test the primers set sensitivity in a serially diluted standard RNA template prepared by 10-fold dilutions. The amplification patterns were observed for each dilution to determine the lowest amount of absolute RNA template required for detectable amplification. The degree of colour intensity of the amplified product as well as the observed electrophoretic pattern during gel electrophoresis was used for the analysis of LAMP amplification.

Quantitative Real Time PCR for miR-cel-miR-39-3p RNA
In order to determine the RNA extraction efficiency, the extracted RNA was reverse transcribed using a commercially available kit (Applied Biosystems/Thermo-Fisher Scientific, Warrington, UK) using miR-specific stem-loop primers as per the manufacturer's instructions. A total of 5 µL of the sample was added to a 96-well plate together with 10 µL reaction mixture (MasterMixTM), along with Multiscribe TM reverse transcriptase (50 U/µL) and 0.19 µL RNAase inhibitor (20 U/µL). The RT reaction was performed at 16 • C for 30 min, followed by 42 • C for 30 min and 85 • C for 5 min and was finally kept at 4 • C. A NTC was considered in every individually run reaction to identify any unspecific amplification. The RT products were quantified immediately by qPCR using TaqMan TM MicroRNA assays (Applied Biosystems/Thermo-Fisher Scientific, UK) in a 96 well plate using the 7900HT Fast Real-Time PCR System (Applied Biosystems, Warrington, UK), as we described before [23]. The quantification cycle (Cq) was determined with instrument default threshold settings (10 SDs above the mean fluorescence of the baseline cycle).

Statistical Analysis
A total sample size of 200 was calculated to assess the performance of the LAMP assay. GraphPad Prism Software version 6.01 for Mac (GraphPad Software, La Jolla, CA, USA) was used for graphs generation. The LAMP detection sensitivity and specificity were calculated using the chi-squared test. TPR (true positive rate), TNR (true negative rate), FPR (false positive rate) and FNR (false negative rate) were calculated according to the following equations: where TP: total number of true positives, TN: total number of true negatives, TN: total number of true negatives, FN: total number of false negatives.

High Resolution Conversation Analysis of SARS-CoV-2 to Guide Oligo Design
It is imperative to critically assess the evolving nature of viruses in identifying conserved gene signatures and guiding the selection of the most appropriate primers. In order to identify important genomic loci, we downloaded and aligned all the available full-length genomes with high coverage sequences (n = 22858) of SARS-CoV-2 by Multiple Alignment using Fast Fourier Transform (MAFFT) [24]. We then compiled in house R-code (available on request) to determine the single nucleotide-based genetic conservation across the length of~30 kb genome. The analysis of the aligned dataset of all genomes in the RStudio generated a total of 18 GB high-resolution nucleotide-by-nucleotide score from 0.0 to 1.0 (1.0 being the highly conserved and 0.0 being the highly divergent). Plotting the assessed genetic divergence, at a cut-off point of 90% similarity along with the genome of the SARS-CoV-2, identified sharp divergence at multiple loci ( Figure 1A). However, most of the genomes maintained high conservation. The divergence at the 5 and 3 ends was primarily due to length heterogeneity, which may be partly as a result of sequencing artifact or potentially coronaviruses ragged termini ( Figure 1B). Owing to high divergence, a stretch of sequence (~400 nucleotides, numbering corresponds to the complete genome of strain SARS-CoV-2/human/USA/VA-DCLS-0285/2020 strain, GenBank Accession Number: MT558705.1) spanning the start of the ORF1b, which encodes for viral RNA-dependent RNA polymerase (RdRP), was targeted to design oligos for the LAMP assay. Additionally, this specific target genomic locus was adjacent to oligos recommended by the World Health Organization (WHO) and Public Health England (PHE) for real-time RT-PCR-based routine identification of CoVID-19 patients, further allowing direct and comparable evaluation of real-time RT-PCR with de novo developed LAMP assay ( Figure 1C). The conserved region of the RdRP gene with the lowest mutation frequencies was used as a template to manually design three sets of basic LAMP primers and was selected with PrimerExplorer V5 for appropriate primer lengths, loop selection and melting temperature optimization ( Figure 1C). In order to preclude the non-specific amplification of common coronaviruses, efforts were made to design primers in the regions where there is a high level of divergence among more than 3 of the 6 total primers in a specific set. Amongst the most suitable targets, the primers with high scores were aligned with MERS-CoV, hCoV-229E, hCoV-OC43, hCoV-NL63, hCoV-HKU1 and SARS-CoV-1 ( Figure 1D). These selected primers were used for further validation and screening.

Determination of the Limit of Detection of the LAMP Assay Using Biochemically Synthesised RNA
In order to assess the robustness of the primers, we used a fully identical in vitro transcribed target RNA unanimously spanning the length of the RdRP-gene based LAMP and qRT-PCR target regions. The pre-determined copy numbers of the biochemically synthesised RNA were 10-fold serially diluted from 10 7 copies to 0 copies of the target gene per reaction. To determine the analytical sensitivity of the assays, we first evaluated their limits of detection (LoD) for both qRT-PCR and LAMP assays. The LoD of the qRT-PCR was 10 copies as evident from the relative fluorescence units ( Figure 2A) and electrophoreses of the amplified products ( Figure 2B). The standard curve generated by the RdRP-based qRT-PCR was linear and generated a coefficient of correlation (R 2 ) = 0.9481 and a slope of −2.6509 ( Figure 2C). Melting curve analysis revealed the specificity of primers for the target gene sequence as all the amplified products showed a uniform melting temperature (Tm) of~75.10 • C and specific amplification patterns ( Figure 2B and data not shown). Compared to the qRT-PCR assay, the LoD for the LAMP that targeted the same RdRP gene was 1 log unit higher (10 2 copies/reaction) ( Figure 2D, upper panel), as assessed by visual observation of the LAMP reaction, where positive reactions turned yellow and negative reactions remained pink when observed by the naked eye. To further confirm the specific amplification of the target region, the gradient LAMP products were visualized by DNA staining and gel electrophoresis for the amplified product, further confirming the detection limit of LAMP ( Figure 2D, lower panel).

Cross-Reactivity of the Novel LAMP Assay When Tested against Other Respiratory and Medically Important Viruses
The SARS-CoV-2 embraces genetic and phenotypic features of several common cold coronaviruses and other viruses of the respiratory tract. Owing to high genetic similarity (up to 96% at nucleotide levels) and common respiratory specimen for clinical identification of CoVID-19 patients, we aimed to investigate any non-specific amplification in the LAMP assay. In order to demonstrate the specificity of the LAMP assay, we used pathogens belonging to five families of the most important medical and respiratory viruses. As shown in Figure 3A, the qRT-PCR specifically detected only the SARS-CoV-2 and this was confirmed by Gel-red staining of amplified products ( Figure 3B). Consistently, no cross-reactivities were observed with the LAMP in both colorimetric detection ( Figure 3C, upper panel) or electrophoreses ( Figure 3C, lower panel). Collectively, a highly specific detection of SARS-CoV-2 was observed for primers set using either of the assays.

Temporal Investigations of the LAMP Assay and Its Impact on the Limit of Detection
One of the major advantages of LAMP is its robustness. In order to determine the optimal time required for sufficient amplification of targeted genes, in vitro transcribed RNA was used as a template in 30 min assays and assessed every 5 min post-start of the reaction. The change in colour was monitored visually by the naked eye. As shown in Table 1, under equivalent conditions, similar results were obtained from between 20-30 min of amplification. Therefore, to improve sensitivity and avoid missing any weak positives, 30 min was selected as the optimal visual interpretation time for the results.
While the change in colour, reflective of a positive reaction, could be detected as early as 20 min post-start of the reaction at the lower copy number, subjective variabilities may result in erroneous interpretation, especially in colorimetric based diagnostic assays. To propose an automated imaging, processing and interpretation of the LAMP based results, we developed a user-friendly device and furnished it with an artificial intelligence based automatic interpretation algorithm.

Manufacture of an Isothermal Nucleic Acid Amplification Device with Colorimetric Detection Features
A device ( Figure 4A) was built with many off-the-shelf electronic components and custom flexible resistive heating elements (5W) and specially designed aluminium heating blocks. Raspberry Pi (RPi) was used to control the device. The one wire interface of the RPi was used to connect 10 digital temperature sensors (DS18B20, Maxim Integrated, San Jose, CA, USA), positioned directly on the PCB boards to monitor heater block temperature changes and provide feedback control. The specially designed aluminium heater blocks to hold 200 µL PCR tubes and the lid heater to prevent condensation were attached directly on top of the surface mount temperature sensors on the respective PCBs with a heat transferring adhesive (TermoGlue, Termopasty Grzegorz Gasowski, Sokoły, Poland). The flexible resistive heating elements were also attached to the heater blocks. To circumvent the need for specialised docks and eliminate user interpretation of the colorimetric results, a Raspberry Pi Camera (RPi) was used. Eight LEDs (LW T733, Osram, Germany) were assembled on the top side of the lid mount PCB to shine light directly into the reaction tubes to achieve consistent lighting within the device. All the above components were assembled into a 3D printed enclosure (14.3 × 10.8 × 6 cm), which was specially designed with openings to access the USB and TCP/IP ports of the RPi. A 20,000 mAh power bank (Anker Powercore, San Francisco, CA, USA) with two 5 V, 2 A output was used to power the device. A Python based control software was used to control the heating, image the progression of the LAMP assay and store the "time-lapse" images and temperature data within a specified folder. The user can initiate a test by either connecting to a screen via the HDMI port or through simply pairing the device with the mobile app via Bluetooth and selecting the required diagnostic assay.

Automated Image Acquisition and Processing through a Template Matching-Based Algorithm
The LAMP assay (eight separate tubes) was remotely started to initiate heating to 65 • C. Images of those test tubes were captured using the inbuilt RPi Camera for every 20 s and were saved in the RPi in the RGB format. Each individual image (90 images in total) consisted of eight frames for each tube with a black background and these were analyzed for 30 min. As the tube area exposing colour changes was fractionally small compared to its background, we first extracted each targeted tube frame ( Figure 4C) from the image before applying an image processing algorithm. In order to process these extracted frames, a reference tube was selected as a template and a template matching algorithm [25] was applied to extract all tubes from the first image. The rationale for the template matching was to search and find the location of a tube in a larger image. It simply slides the template image over the input image to perform the 2-dimensional convolution and compares values to get the maximum overlap to decide the exact similar areas. Assuming that positions of the test-tube do not change over the time of an experiment, images were cropped in an experiment to obtain the tube frames from the entire image. These crops were then saved into a 2-dimensional array for RGB colour space (see equation below). Once extracted, RGB format images were converted to YUV format using the following transformation [26] to minimize diffraction and lighting variabilities in different images: In YUV colour space, the Y channel represented the luminance of the colour, while the U and V channels represented the chrominance ( Figure 4B). Separating the luminance from the chrominance reduced the effect of light changing and shadow noises in each test tube [27]. Finally, the chrominance (U, V) channels from the YUV image were considered for image processing. The chrominance (U, V) values of those extracted test tubes were compared with reference orange test tubes in positive control and reference pink image in negative control test tubes to calculate the sum of absolute difference (SAD) for each of the pixel values. After experiments with eight images set, manual fine tuning of the threshold values and removal of the dark images from the dataset, a SAD threshold value was achieved, which provided 81.25% accuracy in the separation of CoVID-19 positive and negative samples. It was observed that the SAD model was failing to have a common threshold for an image set with a different lighting setup and an image set with bubbles. Therefore, deep learning-based approaches were applied for the images taken in the experiments.

Artificial Intelligence-Assisted Rapid Detection of Colour Changes Associated with the LAMP Reaction
Deep learning is a subdomain of AI which does not require any domain knowledge to work as compared to traditional machine learning. Building upon field knowledge, it is to decide after feature engineering which of the input features work best in modelling the input to output. In contrast, deep learning automatically learns hidden patterns from examples present in the dataset without the need to do it manually. A deep learning Convolutional Neural Network (CNN) [28] architecture was proposed with the bespoke eight layers, as shown in Figure 4D. It consisted of four convolutional layers followed by two dense layers and an output layer. In theory, during training, convolutional layers learn the best features for the given problem and pass those to dense layers and dense layers then act as a classifier and learn how to best classify based on given features. Binary cross-entropy was used as a loss function and Adam for optimizing this CNN model.
For the training of the network, the dataset with 4821 cropped images were shuffled and then split into 9:1 proportion ( Figure 4E). A total of 90% of the data were used to train the network and the remaining 10% were exploited to check how the network behaved on seeing a new image after every epoch. A data generator was implemented that read the data in batches from the dataset directory and fed it to the model; among other benefits such as putting less load on memory, it also made it possible for us to use real-time data augmentation. Data augmentation is the process of adding variation to the samples by adding different transformations. In this case, we randomly used horizontal flips, horizontal and vertical shifts ranging from 10-20 pixels and random brightness. To reduce overfitting, in addition to data augmentation, early stopping with a patience of three epochs was used on validation error, which means if validation error does not drop for three consecutive epochs, training would stop. After multiple repeated experiments, it was found that the model converges after an average of six epochs. Testing of the model was done on two experiments, consisting of 891 images that were never seen by the network before. The best performing network resulted in an accuracy of 98% in classifying tubes based on their colours (images with better light).
In order to assess the temporal impact of the AI-assisted detection of colour changes (indicative of amplification), the RT-LAMP reaction was run with three previously confirmed positive and negative patient samples in addition to known positive and negative controls. Colour changes were assessed every 5 min until the completion of the LAMP reaction at 30 min. Gradual colour changes were detectable with the naked eye as early as 20 min post-start of the reaction ( Figure 5A). Corresponding samples were run on the newly developed device and temporal and real-time colour changes were monitored as described earlier. Depending upon the viral load in the test sample, a clear colour change was detected and calibrated as early as 20 min using device operated processing of the data ( Figure 5B). Once the positive test control was identified as positive, the test was stopped and the results were returned, thus reducing the waiting time and power consumption. As shown in Figure 5B, a template matching algorithm was applied to extract test tubes from images whereas the CNN model was applied to the extracted tubes to train the model. The CNN model was used as a machine learning algorithm to identify colours for each image taken throughout the experiment. Images taken at time tare marked as "t" in Figure 5B and images taken with 20 s gap were fed to the CNN model. Once the positive control test and the negative control test gave the correct results consecutively on three occasions, the LAMP-based test was stopped and the results returned. This approach reduces waiting times for the results and power consumption. Our implementation for these experiments can be found at https://github.com/noumanschaudhry/Ai_assistedLAMP/tree/master.

Validation of AI-LAMP and Comparative Performance in Clinical Settings
In order to assess the field application of the optimized assay, we applied the ai-LAMP to purified RNA spiked with miR-cel-miR-39-3p from CoVID-19 patients. A total of 199 swab samples were collected from CoVID-19 clinically suspected patients during routine COVID-19 screening at the Royal Lancaster Infirmary (RLI), University Hospitals of Morecambe Bay NHS Foundation Trust UK. The extracted RNA from the swab samples were run in parallel for ai-LAMP and two WHO/PHE recommended qRT-PCR targeting the RdRP and N genes of the SARS-CoV-2. This parallel assessment facilitated the assessment of the comparative performance of the ai-LAMP.
The RdRP gene-based qRT-PCR detected a total of 67 positives and 132 negatives in a cohort of 199 patients ( Figure 6A). In contrast, a higher number of positives (n = 88) and a lower number of negatives (n = 111) were detected by the qPCR, which targeted the N gene ( Figure 6B). Interestingly, the ai-LAMP detected a total of 126 positive samples, which constituted several times higher than RdRP and N gene-based qPCR, respectively. Comparative analysis of these three molecular detection assays revealed 58 total true positives (TP), 09 false negatives (FN), 64 true negatives (TN) and 68 false positives (FP) in RdRP-based qRT-PCR compared to RdRP-based LAMP ( Figure 6A). Similarly, upon comparative analysis of the N gene-based qPCR and RdRP-based LAMP, we observed a total of 74 TP, 14 FN, 59 TN and 52 FP ( Figure 6B).
In the current clinical settings, a qRT-PCR targeting two genes (N and RdRP) was conducted to conclusively identify CoVID-19 positive cases and this assay is referred to as cumulative (CUM) qRT-PCR. In this scenario, a sample would be considered as positive only if a Ct value of ≥35 was detected in both N and RdRP-gene based qRT-PCR. Using this approach, we noticed a total of 70 positive and 129 negative samples and an improved true positive (n = 61), false negative (n = 9), true negative (n = 64) and false positive (n = 65) limits ( Figure 6C). Taken together, the cumulative comparative picture of the qPCR and ai-LAMP has identified a superior detection of positive cases ( Figure 6D). In order to confirm this detection performance, all ai-LAMP amplification products were visualised by electrophoresis (data not shown), further confirming the aided-detection and improved implication of ai-LAMP in field conditions. Next, we determined the detection limit of the ai-LAMP in direct correlation with the standard Ct values of the qPCRs. Plotting of ai-LAMP positive and negative data against the linearity of the Ct values revealed that ai-LAMP carried Cp (cycle number at detection threshold) of up to 37 Ct determined by the RdRP gene-based qPCR ( Figure 6E and Supplementary Table S1) or N gene qRT-PCR ( Figure 6F and Supplementary Table S1) of the SARS-CoV-2. This detection was approximately 2 Ct values higher than the detection limit of the standard qPCR. Analysis of the first 96 samples, run in parallel for the ai-LAMP ( Figure 6G and Supplementary Table S1), showed a clear demarcation of the positive and negative samples in the RdRP-gene based ai-LAMP. In order to rule out the quantitative recovery from spiked miRNA, a qRT-PCR was run on 40 randomly selected RNA samples [23]. Based on the quantitative Ct values for miRNA, all samples showed a marked recovery, except a single sample where a low detection of the miRNA was identified ( Figure 6H, Supplementary Table S1 and Supplementary Figure S1).
Collectively, these data highlight the improved specificity and sensitivity of the AI-assisted LAMP assay compared to the naked-eye interpretation of the LAMP result, thus enhancing the timely and automated detection and interpretation of the assay results (see supplementary data).

Discussion
The SARS-CoV-2 is now a global pandemic. Over 216 countries are currently reporting active infections and the number of daily infections and deaths is continuing to rise, especially in the Americas and South East Asia through a series of multiphasic spread [29]. Currently, there is no licensed vaccine or any registered drugs, leaving timely identification of CoVID-19 patients, contact tracing and isolation of positive contacts as the most effective means of containing the pandemic. Among different molecular diagnostic chemistries, LAMP technology provides a promising approach for the rapid and reliable detection in resource-limited settings [17]. Recently, the LAMP technology has been widely applied for the identification of West Nile virus, influenza virus, yellow fever virus, Marburg virus, Ebola virus, Zika virus and other myriads of viruses [30][31][32][33][34][35]. Here, we demonstrated the specificity, sensitivity and utility of a novel ai-LAMP assay for SARS-CoV-2.
The genome of SARS-CoV-2 is approximately 30kb in size with a coding capacity of 9860 amino acids. All of the β-coronaviruses encode for structural (replicases, S, E, M and N) genes in the order of 5 to 3 in the positive sense genome [5,36,37]. A range of qRT-PCRs have been proposed and are referred to by the World Health Organization [29]. While diagnostic assays can be designed on the most conserved region of the viral genome, most of the routinely applied RT-PCR and RT-LAMP have been targeting the S, N, RdRP, E and ORF1a/b genes, mainly due to their high level of transcription and abundance in expression compared to other genes of the SARS-CoV-2 [5,6,38]. For the detection of SARS-CoV-2, Chan et al. [23] have targeted and developed a standard RT-LAMP with LoD of 11.2 RNA copies/reaction using in vitro RNA transcripts. Yan et al. [16] have adapted the ORF1ab to develop RT-LAMP assay with a detection limit of sensitivities of 2 × 10 1 copies per reaction. The majority of these diagnostic assays carry a high level of sensitivity, specificity and repeatability; however, these primarily lack clinical validation and/or optimization on the synthetic targets.
In this study, we have developed and evaluated a novel RT-LAMP in one of the most conserved genes (i.e., RdRP) within the SARS-CoV-2 genome. The RT-LAMP was then directly compared with the currently applied routine diagnostic assays to assess the comparative performance. The RT-LAMP assay developed in this study could detect as low as 100 copies with an in vitro RNA transcript. Importantly, the RT-LAMP has detected the SARS-CoV-2 RNA in 68/199 (34%) and 52/199 (26%) additional specimens that were tested negative by the RdRP-based qRT-PCR and N-based qRT-PCR, respectively. These findings are interesting, both clinically and epidemiologically due to the high proportion of asymptomatic and mildly symptomatic cases of CoVID-19. This higher number of positive sample detection was mainly attributed to the higher sensitivity of the LAMP assay. Moreover, owing to multi-gene amplification in the qRT-PCR, the overall detection of positive cases was limited. The apparently healthy people have been suggested to be a major source of virus propagation and the basis of epidemics within the community [39,40]. Therefore, a highly sensitive and specific test is needed to identify cases with a low viral load. The RT-LAMP detected more positive samples that were otherwise negative by routinely applied qRT-PCR assay. In order to assess the potential false positive identification, we run electrophoreses and sequencing of the N gene. The use of a spiked RNA standard that is not expressed in humans (cel-miR-39-3p) helped to confirm the effectiveness of the RNA extraction approach using commercial kits (Qiagen). In addition, we used a fixed total RNA concentration in all experiments, allowing for better comparisons across groups.
The main challenges of using the colorimetric approach are the background which changes the colour perspective, issues in identifying small changes, bubbles in the test tubes, a relatively small area corresponding to colour change and pixel variation due to camera flash and background reflections. In addition to these issues, the SAD approach required manual finding for the suitable threshold due to a different lighting setup and image set with bubbles. In addition to this, we tried different image processing algorithms such as histogram comparisons, conversions to other colour-spaces and calculating colour differences, removing brightness through YUV transformation to get rid of brightness variation, edge detection approach to extract tube sections only and threshold segmentation approach. All the approaches failed to deliver better accuracy in separation due to the presence of bubbles, small tube area and camera light change over time. Out of the image processing approaches mentioned above, SAD worked best, however for its full integration, we had to decide the threshold manually for every image set, which introduces another subjective variable that needs optimization for every experiment. Theoretically, with extensive experimentation in altering and optimizing the parameters, acceptable features can be acquired. Therefore, the CNN based model has been used, which can exploit these underlying patterns and find the best parameters that are robust, keeping in mind those different types of noise that can be present. Although a CNN based approach was used to overcome noise related issues, image processing algorithms were applied to extract tubes before applying the CNN approach. In this hybrid approach, test tubes are extracted using image processing algorithms and then deep learning algorithms are applied to apply fine tuning of images algorithms and classify colours with more accuracy. This approach demanded less expert analysis and fine-tuning, exploiting the tremendous amount of image set we generated through the experiments with different scenarios. The CNN needs to be applied only on extracted test tubes and therefore saves significant computing resources and training efforts compared to processing of the entire image. The trained model, after compression, has been successfully moved to Rpi to identify colour changes in test tubes. The study offered 98% accuracy for images taken and the duration of testing could be dynamically controlled to reduce the length of operating time and heating, with a resulting reduction in energy consumption by the device. Despite the SAD based approach resulting in 82.1% accuracy for the images after 30 min, this approach failed with other datasets containing bubbles and different background lights as different threshold values were manually produced for each image set. Therefore, a CNN approach was utilized in our experiments to generalize the classification for orange and pink test tubes with different background light and bubbles. Although deep learning training complexity and time were higher compared to standard image processing algorithms, testing images with the trained model does not differ substantially on complexity and time compared to pipeline of standard image processing algorithms. Even though the CNN approach gave modest improvement in accuracy (98% from 81.5%), these improvements are significant in the field of CoVID-19 testing.
Collectively, our data show that the newly established ai-LAMP is highly specific for the detection of SARS-CoV-2 RNA from extracted respiratory tract clinical specimens. The application of this novel LAMP assay may be particularly useful for detecting COVID-19 cases with low viral loads and when testing upper respiratory tract specimens (nasal or oral swabs) from patients. Development of ai-LAMP into a multiplex assay that can simultaneously detect other human-pathogenic coronaviruses and respiratory pathogens may further increase its clinical utility in the future.
Supplementary Materials: The following are available online at http://www.mdpi.com/1999-4915/12/9/972/s1, Figure S1: Optimization and raw data on the LAMP optimization, Table S1: Data on the comparison of the qRT-PCR and LAMP. Funding: The authors wish to express our sincere appreciation to the BBSRC for allowing us to repurpose the LAMP prototypes produced in the grant BB/R012695/1 to be used for SARS-CoV-2 laboratory testing at The University of Lancaster. We would like to thank the support of BBSRC (BB/M008681/1 and BBS/E/I/00001852) and British Council (172710323 and 332228521) at Division of Biomedical and Life Sciences, Lancaster University, UK. We would also like to thank Brunel University London and the University of Surrey for providing some financial support to rapidly produce these devices.