key: cord-0926682-hvkqdfmq authors: Samacoits, Aubin; Nimsamer, Pattaraporn; Mayuramart, Oraphan; Chantaravisoot, Naphat; Sitthi-amorn, Pitchaya; Nakhakes, Chajchawan; Luangkamchorn, Lumrung; Tongcham, Phongsakhon; Zahm, Ugo; Suphanpayak, Suchada; Padungwattanachoke, Natta; Leelarthaphin, Nutcha; Huayhongthong, Hathaichanok; Pisitkun, Trairak; Payungporn, Sunchai; Hannanta-anan, Pimkhuan title: Machine Learning-Driven and Smartphone-Based Fluorescence Detection for CRISPR Diagnostic of SARS-CoV-2 date: 2021-01-20 journal: ACS Omega DOI: 10.1021/acsomega.0c04929 sha: 3b4af0386f8294b22e8a0fa0a1d378632a4b11a6 doc_id: 926682 cord_uid: hvkqdfmq [Image: see text] Rapid, accurate, and low-cost detection of SARS-CoV-2 is crucial to contain the transmission of COVID-19. Here, we present a cost-effective smartphone-based device coupled with machine learning-driven software that evaluates the fluorescence signals of the CRISPR diagnostic of SARS-CoV-2. The device consists of a three-dimensional (3D)-printed housing and low-cost optic components that allow excitation of fluorescent reporters and selective transmission of the fluorescence emission to a smartphone. Custom software equipped with a binary classification model has been developed to quantify the acquired fluorescence images and determine the presence of the virus. Our detection system has a limit of detection (LoD) of 6.25 RNA copies/μL on laboratory samples and produces a test accuracy of 95% and sensitivity of 97% on 96 nasopharyngeal swab samples with transmissible viral loads. Our quantitative fluorescence score shows a strong correlation with the quantitative reverse transcription polymerase chain reaction (RT-qPCR) Ct values, offering valuable information of the viral load and, therefore, presenting an important advantage over nonquantitative readouts. COVID-19, caused by the SARS-CoV-2 virus, has spread rapidly across the world within the past few months, infecting more than 30 million people and resulting in more than a million deaths globally. 1 Early evidence suggests that people who are infected with SARS-CoV-2, both symptomatic and asymptomatic, can be carriers of the virus and transmit it to others. 2,3 Therefore, being able to extensively test individuals and quarantine those shown to be infected early on in the disease progression is crucial to slow the rate of transmission. The current gold standard protocol for the nucleic acidbased detection, quantitative reverse transcription polymerase chain reaction (RT-qPCR), is expensive and laborious and requires costly equipment and highly trained personnel. Many developing countries and health care settings have limited access to such resources, restricting their capacity to sufficiently test their populations. Another method known as loop-mediated isothermal amplification (LAMP) is faster and simpler 4 but can sometimes be nonspecific. 5 Therefore, having a low-cost, rapid, and sensitive diagnostic is essential to minimize the morbidity and mortality from COVID-19. A novel CRISPR-based diagnostic method is an attractive option due to its rapid, sensitive, specific, and easy to implement characteristics. 6−9 One caveat is that its readout mostly relies on a simple visual inspection, which is prone to errors, particularly for discriminating samples with low viral counts. This quantification can be performed using fluorescence readers but is typically costly and inaccessible to many health professionals. To address this limitation, we sought to develop a low-cost, portable smartphone-based fluorescence detector for the detection of SARS-CoV-2 through the CRISPR-based diagnostic platform. 10−13 To achieve rapid and sensitive testing, we employed a CRISPR-Cas12a based method, known as DETECTR, that exploits the collateral activity of the Cas12a enzyme to cleave a fluorophore quencher-labeled nucleotide reporter, giving off fluorescence signals in the presence of SARS-CoV-2 RNA. This platform has proven to be simple, quick, and highly sensitive 6, 12, 14 (Figure 1a) . A guide RNA targeting a specific region of the SARS-CoV-2 N-gene, recommended by the World Health Organization's (WHO) and the U.S. Centers for Disease Control and Prevention's (CDC) protocols, was utilized for optimal sensitivity and specificity of the detection. 11, 15, 16 To perform fluorescence reading, we designed a mobile phone-based device that enabled fluorescence imaging of the samples ( Figure 1b) and custom software that supported image processing and straightforward interpretation of results ( Figure 1c ). From these outputs, users will be able to conveniently image the sample with a mobile phone and receive a result instantaneously. To fabricate the fluorescence detector, a 5 mm dome-capped 467 nm blue light emitting diode (LED) was placed under the sample to excite the reporter 6-carboxyfluorescein (6-FAM) quencher-labeled probe within the diagnostic assay. The LED was placed at a 90°angle from the emission path to minimize the background noise for the imaging. An optical diffuser sheet was inserted above the LED to create uniform illumination around the sample. Following excitation, the sample fluorescence emission was selectively transmitted through a low-cost amber emission filter (590 ± 20 nm) and collected through a convex lens by a camera. The convex lens provided an optical demagnification of the sample view, permitting sharp imaging of the sample at a short distance. A three-dimensional (3D)-printed housing was adopted to provide a dark environment for fluorescence imaging. It also aligned the optical path between the excitation light from the LED to the sample and the fluorescence emission from the sample to the phone camera. The housing was easily assembled from three partsa sample tray capable of holding a strip of eight PCR tubes, an imaging compartment, and a phone holder (Figure 1b) . The device was designed to be portable, easy to fabricate, and cost-effective. Using 3D printing and inexpensive optics, the device can be built for as low as $10. Once captured by the phone camera, the images were sent to the cloud to be analyzed. Taking advantage of the spatial Step-by-step summary of the custom software for the quantification of SARS-CoV-2. stability of the system, the image was first cropped around the expected position of the test tube, edge detected using pixelwise forest classification, 17 and subsequently segmented with hierarchical segmentation to extract the pixels corresponding to the liquid inside the tube and the background. Each color channel of the two regions was averaged and then projected into the hue, saturation, value (HSV) space. The angle between the two Hue mean values was computed 18 and used as a score indicative of the fluorescence intensity of the liquid. The intensity was then used to build a likelihood of the sample containing SARS-CoV-2. Next, we examined parameters that are important to the sensitivity of the detection system. We looked into various smartphone models to compare their sensor performance. We tested two models from the two main operating systems; model 1 was one of the oldest supported smartphone models on the market, whereas model 2 was a more recent smartphone model with high-performance cameras at a low cost. To evaluate sensitivity, we imaged tubes containing relevant 6-FAM concentrations with either phone model and quantified the increase in fluorescence signals. The fluorescence was relatively linear in the dye concentration range between 0.05 and 0.5 μM. The slope was calculated as a measure of the detection sensitivity. Model 2 showed brighter signals consistent with its larger camera aperture (f/1.79) ( Figure 2a , left). However, the detection sensitivity was similar for the two phone models, suggesting that the smaller aperture size (f/ 2.2) of model 1 sufficed for our application. In our case, we proceeded with the second model because of its built-in camera application that allowed extensive control of the camera settings. In general, any smartphone with an f/2.2 aperture and a complementary metal−oxide−semiconductor (CMOS) sensor should give similar detection sensitivity, while the camera resolution is not critical for imaging a relatively large object in this application. We next identified optimal values for key imaging parameters, including illumination intensity and exposure time. Using a similar approach, we found that the sensitivity improved significantly as the illumination power increased from 4.29 to 9.22 mW/cm 2 , while a minimal improvement was observed at 15.90 mW/cm 2 . Fixing the illumination power at 9.22 mW/cm 2 , the signals were optimized and remained unsaturated throughout the entire range of concentrations at 1 s exposure time (Figure 2a) . Once we identified optimal imaging settings, we sought to quantify and detect the presence of SARS-CoV-2. Various concentrations of RNA-encoding SARS-CoV-2 N-gene were prepared as templates. The templates were reverse-transcribed, amplified, and detected with the CRISPR assay platform, as shown in Figure 1a . Two different quencher-labeled probes including a BHQ-quenched probe and a Zen dual-quenched probe, known to reduce basal fluorescence, were assessed. We found that the BHQ probe showed significantly higher signals for all template concentrations. The limit of the detection (LoD) was as low as 6.25 copies/μL (Figure 2b ). This is a clinically relevant range for viral loads found in the throat swabs and sputum of COVID-19 patients, ranging between 10 and 10 4 copies/μL. 3, 19, 20 The signal difference was apparent within 5 min, and the signal began to level off at 15 min, in which the signal for all of the positives doubles the signals of the negative control. The LoD of our system was close to that of the RT-qPCR at 1−3.2 copies/μL 21 and lower than that of the previously reported CRISPR-Cas12-based lateral flow assay at 10 copies/μL. 12 The improved LoD suggests that the detection sensitivity of the CRISPR-Cas diagnostic platform could be enhanced by our low-cost fluorescence detection system. We further verified our system with 115 nasal swab samples collected since February 2020 at Rajavithi Hospital, Thailand. We observed a significant separation of the fluorescence score between the positive and negative samples (Figure 2c, left) . The score was then used to build a binary classifier, specifically logistic regression, to classify a test tube image into negative/ positive and assigning to it a probability of infection. A fourfold cross-validation using a logistic regression trained on the fluorescence score showed an average area under the ROC curve of 0.93 (Figure 2c , middle) and a global accuracy of 90%. Furthermore, we observed a strong correlation between the fluorescence score and the RT-qPCR Ct values of the samples. Samples with high viral loads (Ct < 33) produced a uniformly high fluorescence score, yielding a prediction accuracy, sensitivity, and specificity of 95, 97, and 93%, respectively ( Table 1 ). The errors mostly lay within the samples with lower viral loads of Ct > 33, which is a LoD of the CRISPR-based SARS-CoV-2 detection found previously in clinical samples 10, 12 (Figure 2c, right) . Our accuracy and specificity were marginally lower than those shown in prior studies with similar CRISPR-Cas diagnostic platforms. As a portion of the samples was collected during the early months of the pandemic, we believe that the relatively lower performance can be attributed partly to the sample degradation due to an extended storage duration and multiple freeze−thaw cycles prior to our testing. By training the model on more clinical samples with low viral loads, we will be able to further fine-tune our model to more accurately predict such edge cases and further improve the model and the overall test performance. Nonetheless, our diagnostic system has proven to be sufficient for screening of infectious individuals as previous findings suggest minimal infectivity in patients with high Ct values and their low likelihood of viral transmission. 22, 23 Moreover, the viral count is indicative of disease severity and infectivity of the infected individuals. Our system's ability to report a quantitative value correlated with the viral load offers critical quantitative information that cannot be obtained from current readout methods, such as visual inspection or lateral flow strips. Our device builds upon the knowledge of mobile phone-based detection platforms 24−27 and has been optimized for CRISPR diagnostic assays of SARS-CoV-2 detection. The device has been carefully designed such that it is simple to use for the general public, easy to fabricate through 3D printing, portable, and cost-effective. The platform is suitable for resource-limited settings and particularly advantageous where urgent testing is required, such as dental clinics, airports, border checkpoints, and unplanned medical operations. Finally, the ability to have images and results automatically uploaded to a central server can serve as a potential means to keep track of the COVID-19 transmission in real time, which has previously been difficult to do. This system has the potential to improve data transparency and inform the public about current infectious disease diagnoses and population-based trends so that both individuals and officials can take necessary actions to prevent, intervene, or mitigate on-going endemics. IV.I. Device Fabrication. A 5 mm dome-capped 467 nm LED (VCC, LTH5MM12VFR4600), resistors, and an LED driver were mounted on a custom PCB board (Supporting Information Figure S1 ) fabricated by JLCPCB and powered by a 9 V battery. A thin, low-cost camera optical diffuser (Selens) was placed on top of the LED for a uniform light distribution. A low-cost photographic color correction filter (Selens) was positioned in front of the sample to select desirable emission wavelengths before going into the collection lens and the phone camera. A 20× convex lens was inserted in front of the camera to adjust the effective focal length and allow sharp imaging of an object in a short distance. The device housing was assembled from three components, including a sample tray, an imaging compartment, and a phone holder. The CAD design of the housing was drawn using SolidWorks. The device was fabricated using a 3D Flashforge Creator Pro printer with a 1.75 mm black PLA filament. The CAD drawings of the IV.II. Image Acquisition. To prepare for fluorescence imaging, a smartphone was slid into the 3D-printed phone holder component and pushed all the way in so that the phone camera aligned with the fluorescence emission path and the collection lens. A strip of 0.1 mL PCR tubes containing the CRISPR diagnostic samples was placed in the sample tray and then slid into the imaging compartment. Then, the LED was turned on through a switch on the battery tray. The device can be hand-held and used to image the samples vertically, as shown in Figure 1b . Alternatively, the device can be used horizontally with the long side of the phone placed on a surface, and the samples are imaged in a landscape mode. For the landscape imaging, the imaging compartment is assembled to the phone holder with a 90°clockwise rotation. In our experiments shown in Figure 2a , an iPhone 6s was used as the old smartphone model, model 1, whereas a Xiaomi Redmi Note 8 was used as the more recent smartphone model, model 2. Detailed information on camera settings can be found in the Supporting Information. IV.III. Machine Learning Algorithm for Sample Classification. Once acquired, the image was first cropped around the expected position of the test tube and was processed by a segmentation algorithm that extracted the pixels corresponding to the liquid inside the tube. Once the liquid was segmented, two regions inside and outside the liquid were extracted and used to build a likelihood of infection. To calculate a score of infection from the segmented imaged tube, each color channel of the two regions outside and inside the liquid were averaged and then projected into the HSV space. The angle between the two Hue mean values was computed and used as a score indicative of the fluorescence intensity of the liquid. From that score, we built a logistic regression classifier to classify a test tube image into negative/positive and assigned to it a probability of infection. A fourfold crossvalidation using a logistic regression trained on the fluorescence score was performed to compute an average area under the ROC curve and a global accuracy of the prediction. More details of the algorithm can be found in the Supporting Information. The source codes for the image analyses and test prediction can be found at https://gitlab. com/AubinS/covidscan. IV.IV. CRISPR Diagnostic Assay with Synthetic Templates. Synthetic RNA template for SARS-CoV-2 (Supporting Information Table S1) was produced from T7 Riboprobe in vitro transcription systems (Promega) using a DNA template containing the T7 promoter, according to the manufacturer's protocol. The in vitro transcribed RNA was subsequently extracted using a GenUP Total RNA Kit (BiotechRabbit, Germany). The template was serially diluted to six different concentrations 10 6 , 1000, 125, 62.5, 12.5, and 6.25 viral RNA copies/μL and used as detection templates, as shown in Figure 2b . To perform RT-RPA, a TwistAmp Basic Kit (TwistAMP, UK, TABAS03KIT) and RevertAid Reverse Transcriptase (Thermo Scientific, USA, EP0442) were used together with the forward and the reverse primer binding sites to N-gene shown in Table S1 . The RT-RPA reactions were setup according to Table S2 and incubated at 39°C for 30 min. The samples were then heated at 75°C for 5 min to deactivate the reverse transcriptase and halt the amplification. Next, the CRISPR detection was carried out by adding a crRNA (Table S1 ), Cas12a enzyme (New England Biolabs, USA, M0653T), 5′ 6-FAM/3′ BHQ-1 dual-labeled fluorescent probes (0.5 μM final concentration), and NEBuffer 2.0 (New England Biolabs, USA, B7002S) to 1 μL of the previously amplified dsDNA templates (Table S3 ). The reactions were incubated at 39°C and imaged with our custom smartphonebased fluorescent imaging device every 5 min for the duration of 30 min. IV.V. CRISPR Diagnostic Assay with Clinical Samples. A total of 115 nasopharyngeal swab samples were collected from individuals showing COVID-19-like symptoms starting in February 2020 at Rajavithi Hospital, the primary public medical center under Thailand's Ministry of Public Health. Briefly, 200 μL of each sample was aliquoted to perform RNA extraction using a commercial nucleic acid extraction kit, MagDEA Dx SV (Precision System Science, USA, E1300). The RNA was eluted into a 50 μL volume, and from which 11 μL was transferred to perform RT-RPA and CRISPR-Cas12a detection, as described in Section IV.IV. A positive control with 10 6 viral RNA copies/μL and a negative control of a non-SARS-CoV-2 RNA template were tested together with every batch of samples to ensure proper functioning of the diagnostic assay. World Health Organization Coronavirus Disease 2019 (COVID-19) Temporal dynamics in viral shedding and transmissibility of COVID-19 Virological assessment of hospitalized patients with COVID-2019 Loop-mediated isothermal amplification of DNA Brief review of monitoring methods for loop-mediated isothermal amplification (LAMP) CRISPR-Cas12a target binding unleashes single-stranded DNase activity Nucleic acid detection with CRISPR-Cas13a/C2c2 SHERLOCK: nucleic acid detection with CRISPR nucleases Field-deployable viral diagnostics using CRISPR-Cas13. Science Pointof-care testing for COVID-19 using SHERLOCK diagnostics medRxiv 2020 CRISPR− Cas12-based detection of SARS-CoV-2 Massively multiplexed nucleic acid detection with Cas13 Detection of severe acute respiratory syndrome coronavirus 2 and influenza viruses based on CRISPR-Cas12a 2019-nCoV) Real-TimeRT-PCR Diagnostic Panel, 2020. (16) World Health Organization. Diagnostic detection of Wuhan coronavirus 2019 by real-time RT-PCR In Structured Forests for Fast Edge Detection Viral load of SARS-CoV-2 in clinical samples SARS-CoV-2 Viral Load in Upper Respiratory Specimens of Infected Patients Predicting Infectious Severe Acute Respiratory Syndrome Coronavirus 2 From Diagnostic Samples Duration of infectiousness and correlation with RT-PCR cycle threshold values in cases of COVID-19 Quantitative imaging with a mobile phone microscope Fluorescent imaging of single nanoparticles and viruses on a smart phone A smartphone-based diagnostic platform for rapid detection of Zika, chikungunya, and dengue viruses Point-of-care quantification of blood-borne filarial parasites with a mobile phone microscope ACS Omega http://pubs.acs.org/journal/acsodf Article