KR102509751B1 - Method and Apparatus for Rapidly Designing all Valid Primers that Simultaneously Satisfy Primer Restriction Condition and Specificity Condition in Large DNA Sequence Database using GPU - Google Patents

Method and Apparatus for Rapidly Designing all Valid Primers that Simultaneously Satisfy Primer Restriction Condition and Specificity Condition in Large DNA Sequence Database using GPU Download PDF

Info

Publication number
KR102509751B1
KR102509751B1 KR1020200149973A KR20200149973A KR102509751B1 KR 102509751 B1 KR102509751 B1 KR 102509751B1 KR 1020200149973 A KR1020200149973 A KR 1020200149973A KR 20200149973 A KR20200149973 A KR 20200149973A KR 102509751 B1 KR102509751 B1 KR 102509751B1
Authority
KR
South Korea
Prior art keywords
primers
primer
gpu
filtering
pair
Prior art date
Application number
KR1020200149973A
Other languages
Korean (ko)
Other versions
KR20220063977A (en
Inventor
김민수
배정민
Original Assignee
한국과학기술원
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 한국과학기술원 filed Critical 한국과학기술원
Priority to KR1020200149973A priority Critical patent/KR102509751B1/en
Publication of KR20220063977A publication Critical patent/KR20220063977A/en
Application granted granted Critical
Publication of KR102509751B1 publication Critical patent/KR102509751B1/en

Links

Images

Classifications

    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16BBIOINFORMATICS, i.e. INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR GENETIC OR PROTEIN-RELATED DATA PROCESSING IN COMPUTATIONAL MOLECULAR BIOLOGY
    • G16B50/00ICT programming tools or database systems specially adapted for bioinformatics
    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16BBIOINFORMATICS, i.e. INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR GENETIC OR PROTEIN-RELATED DATA PROCESSING IN COMPUTATIONAL MOLECULAR BIOLOGY
    • G16B30/00ICT specially adapted for sequence analysis involving nucleotides or amino acids
    • G16B30/10Sequence alignment; Homology search
    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16BBIOINFORMATICS, i.e. INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR GENETIC OR PROTEIN-RELATED DATA PROCESSING IN COMPUTATIONAL MOLECULAR BIOLOGY
    • G16B45/00ICT specially adapted for bioinformatics-related data visualisation, e.g. displaying of maps or networks

Landscapes

  • Physics & Mathematics (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Evolutionary Biology (AREA)
  • General Health & Medical Sciences (AREA)
  • Theoretical Computer Science (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Biotechnology (AREA)
  • Spectroscopy & Molecular Physics (AREA)
  • Biophysics (AREA)
  • Medical Informatics (AREA)
  • Bioethics (AREA)
  • Databases & Information Systems (AREA)
  • Data Mining & Analysis (AREA)
  • Chemical & Material Sciences (AREA)
  • Analytical Chemistry (AREA)
  • Proteomics, Peptides & Aminoacids (AREA)
  • Measuring Or Testing Involving Enzymes Or Micro-Organisms (AREA)

Abstract

GPU를 활용하여 대규모 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 모든 프라이머들을 빠르게 디자인하는 방법 및 장치가 제시된다. 일 실시예에 따른 GPU를 활용하여 대규모 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 모든 프라이머들을 빠르게 디자인하는 장치는, GPU 프라이머를 활용하여 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 프라이머들을 디자인하기 위한 전체적인 연산을 수행하며, 연산 과정에서 생성하는 해쉬맵을 포함하는 데이터 구조는 메인 메모리에 저장하여 사용하고, 초기 입력으로 사용되는 상기 DNA 서열 데이터베이스 및 후보 프라이머들을 기록하는 중간과정의 파일의 경우 별도의 하드디스크에 파일 형태로 저장해두고 필요한 경우 읽어와 사용하는 CPU; 및 대규모 연산을 필요로 하는 경우에 상기 CPU를 통해 상기 GPU 프라이머의 일부 연산에 대한 명령을 전달 받아 구동되며, GPU 메모리는 상기 메인 메모리로부터 연산에 필요한 데이터를 복사 받아 커널 연산을 수행한 뒤 그 결과에 대해 상기 메인 메모리로 다시 복사하는 GPU를 포함하여 이루어질 수 있다. A method and apparatus for rapidly designing all effective primers that simultaneously satisfy primer restriction conditions and specificity conditions in a large-scale DNA sequence database using a GPU are provided. An apparatus for rapidly designing all valid primers that simultaneously satisfy primer restriction conditions and specificity conditions in a large-scale DNA sequence database by utilizing GPU according to an embodiment is a GPU primer to determine primer restriction conditions and specificity conditions in a DNA sequence database. The entire operation is performed to design effective primers that satisfy the same requirements, the data structure including the hash map generated during the operation is stored in the main memory, and the DNA sequence database and candidate primers used as initial input are recorded. In the case of a file in the middle process to be stored in the form of a file on a separate hard disk, the CPU reads and uses it if necessary; And when a large-scale operation is required, it is driven by receiving commands for some operations of the GPU primer through the CPU, and the GPU memory receives data necessary for operation from the main memory, performs kernel operation, and then performs kernel operation as a result. It can be made by including a GPU to copy back to the main memory for.

Description

GPU를 활용하여 대규모 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 모든 프라이머들을 빠르게 디자인하는 방법 및 장치{Method and Apparatus for Rapidly Designing all Valid Primers that Simultaneously Satisfy Primer Restriction Condition and Specificity Condition in Large DNA Sequence Database using GPU}Method and Apparatus for Rapidly Designing all Valid Primers that Simultaneously Satisfy Primer Restriction Condition and Specificity Condition in Large DNA Sequence Database using GPU}

아래의 실시예들은 프라이머를 디자인하는 방법 및 장치에 관한 것으로, 더욱 상세하게는 주어진 대규모 서열 데이터베이스에 대해 사용자에 의해 주어진 여러 필터링 제약조건들을 만족하고 상동성 검사(Homology test)를 자체적으로 수행함으로써 그 특이성(Specificity)이 검증된 유효한 모든 프라이머 쌍들을 GPU를 활용하여 빠르게 고 효율적으로 디자인하는 방법 및 장치에 관한 것이다. The following examples relate to a method and apparatus for designing primers, and more particularly, by satisfying various filtering constraints given by a user for a given large-scale sequence database and performing a homology test on its own. It relates to a method and apparatus for rapidly and efficiently designing all valid primer pairs whose specificity has been verified using a GPU.

중합효소연쇄반응(Polymerase Chain Reaction, PCR)은 표적 DNA의 일부를 시험관 내에서 대량으로 증폭시킬 수 있는 방법으로 관련된 생물학적 실험을 수행하는 병원, 연구소, 대학교 등에서 널리 사용되고 있다. 특히, 실시간 RCR(Real-time PCR)로도 알려진 정량적 PCR(Quantitative PCR, qPCR)의 경우 PCR 과정 중에 실시간으로 특정 DNA 분자의 산물을 모니터링하여 DNA 분자의 증폭과 양을 동시에 감지하는데 널리 이용되는 기본적인 기술로, 바이러스 검출(virus detection), 유전자 변형 농산물(Genetically Modified Organism, GMO) 검출, 유전자 지문 및 친자 확인을 통한 법의학적 분석 등 많은 영역에서 활용되고 있다. 또한, 이러한 qPCR과 관련된 실험에서 좋은 결과를 얻기 위해서는 표적 서열(Target Sequence)에 적합한 프라이머 디자인을 하는 것이 매우 중요하다. 프라이머는 DNA 합성 시 개시점이 되는 짧은 유전자 서열로, DNA 시퀀싱(Sequencing)이나 PCR 실험을 위해 필수적이다.Polymerase Chain Reaction (PCR) is a method that can amplify a portion of target DNA in large quantities in vitro, and is widely used in hospitals, research institutes, universities, etc. that perform related biological experiments. In particular, quantitative PCR (qPCR), also known as real-time PCR (RCR), is a basic technique widely used to simultaneously detect the amplification and quantity of DNA molecules by monitoring the product of a specific DNA molecule in real time during the PCR process. It is used in many areas, such as virus detection, genetically modified organism (GMO) detection, and forensic analysis through genetic fingerprinting and paternity confirmation. In addition, in order to obtain good results in such experiments related to qPCR, it is very important to design primers suitable for the target sequence. A primer is a short gene sequence that serves as a starting point for DNA synthesis, and is essential for DNA sequencing or PCR experiments.

도 1은 일반적인 정방향 프라이머(Forward Primer)와 역방향 프라이머(Reverse Primer)가 DNA 표적서열에 결합된 상태를 나타내는 도면이다. 보다 구체적으로, 도 1은 분리된 DNA 가닥(202)에 각각 정방향 프라이머(Forward Primer)(205)와 역방향 프라이머(Reverse Primer)(203)가 각 표적의 정방향 탬플릿(Template)(201)과 역방향 탬플릿(207)에 상보적으로 결합하여 DNA 중합효소가 형성되는 예시를 나타낸다.1 is a view showing a state in which a general forward primer and a reverse primer are bound to a DNA target sequence. More specifically, FIG. 1 shows that a Forward Primer 205 and a Reverse Primer 203 are respectively applied to the separated DNA strand 202 to form a forward template 201 and a reverse template of each target. (207) shows an example in which DNA polymerase is formed by complementary binding.

도 1에 도시된 바와 같이, 양쪽의 새로운 정방향 가닥(206)과 역방향 가닥(204)은 5'에서 3' 방향으로 합성이 이루어지며, 도면에서처럼 특정 서열을 합성하기 위해서는 정방향 프라이머(205)와 역방향 프라이머(203)의 쌍이 필요하다.As shown in FIG. 1, new forward strands 206 and reverse strands 204 on both sides are synthesized in the 5' to 3' direction, and as shown in the figure, in order to synthesize a specific sequence, forward primers 205 and reverse A pair of primers 203 are required.

일반적으로 합성 과정에 사용되는 고품질 프라이머들은 프라이머 또는 프라이머 쌍에 대해 자체적인 싱글/쌍 프라이머 필터링(Single/Pair Primer Filtering) 조건을 만족해야 할 뿐 아니라, 비표적 서열들은 증폭시키지 않도록 하기 위한 상동성 검사(Homology Test) 또한 수행하여 특이성 검증 또한 거쳐야 한다. 프라이머를 디자인하는데 있어서 제약 조건은 싱글 프라이머 필터링(Single Primer Filtering) 조건과 쌍 프라이머 필터링(Pair Primer Filtering) 조건이 있는데, 싱글 프라이머 필터링(Single Primer Filtering) 조건에는 프라이머의 길이, 온도(℃), GC content(%), Self-Complementarity, 3' End Self-Complementary, 연속된 염기, end stability(G value)가 있고, 쌍 프라이머 필터링(Pair Primer Filtering) 조건에는 길이 차이, 온도 차이, 생성물의 길이, Pair-Complementary, 3' End Pair-Complementary가 있다. In general, high-quality primers used in the synthesis process not only have to satisfy the Single/Pair Primer Filtering condition for the primer or primer pair, but also a homology test to prevent amplification of off-target sequences. (Homology Test) must also be performed to verify specificity. Constraints in designing primers include single primer filtering conditions and pair primer filtering conditions. The single primer filtering conditions include primer length, temperature (℃), GC There are content (%), Self-Complementarity, 3' End Self-Complementary, consecutive bases, and end stability (G value). Pair Primer Filtering conditions include length difference, temperature difference, product length, pair -Complementary, 3' End Pair-Complementary.

상기 언급한 싱글 프라이머 필터링(Single Primer Filtering) 조건과 쌍 프라이머 필터링(Pair Primer Filtering) 조건들을 고려하며 손으로 직접 프라이머를 디자인하는 것은 시간이 많이 소요되고 잘못된 결과를 유발할 수 있기 때문에 상기 언급된 조건들을 고려하며 적절한 프라이머를 디자인하기 위한 많은 자동화 방법들이 고안되었다.Since designing primers by hand while considering the above-mentioned Single Primer Filtering conditions and Pair Primer Filtering conditions is time-consuming and may cause incorrect results, the above-mentioned conditions are not considered. A number of automated methods have been devised to take into account and design appropriate primers.

하지만, 프라이머를 디자인하는 종래의 기술들은 일반적으로 상기 언급한 프라이머 디자인 제약 조건 외에 고품질 프라이머 디자인에 필수적인 특이성 검증을 동시에 수행하지 못하는 경우가 일반적이다. 따라서 종래의 방법들은 이러한 특이성 검증을 위해 추가적으로 BLAST와 같은 툴을 사용하여 추가적인 상동성 검사 과정을 거쳐야 한다는 한계점을 가지고 있다. 특히, 하나의 표적 DNA 서열에 대한 프라이머가 아닌 대규모 DNA 서열 데이터베이스에 대하여 엄격한 제약조건 만족하며 특이성 검증 또한 통과하는 다수의 프라이머를 동시에 디자인하는 것은 더욱 어려운 문제이다.However, conventional techniques for designing primers generally fail to simultaneously verify specificity necessary for high-quality primer design in addition to the above-mentioned primer design constraints. Therefore, conventional methods have a limitation in that an additional homology check process using a tool such as BLAST is additionally required to verify this specificity. In particular, it is more difficult to simultaneously design a plurality of primers that satisfy strict constraints on a large-scale DNA sequence database and pass specificity verification, rather than primers for one target DNA sequence.

이과 관련하여 개발된 MRPrimer는 하둡의 맵리듀스(MapReduce) 프레임워크를 기반으로 DNA 서열 데이터베이스에 대해 상기 언급한 프라이머에 대한 제약 조건을 만족하는 프라이머를 찾는 동시에 특이성 검증을 수행하여 최적의 프라이머를 디자인할 수 있는 파이프라인이다. 이러한 MRPrimer를 통해 출력한 프라이머들은 그 특이도 또한 실험적으로 검증되었기 때문에 MRPrimerW, MRPrimerV 등의 프라이머 디자인을 도와주는 웹 사이트의 기반 알고리즘으로 사용되고 있다.MRPrimer, developed in this regard, is based on Hadoop's MapReduce framework to design optimal primers by searching for primers that satisfy the above-mentioned primer constraints in the DNA sequence database and at the same time performing specificity verification. It is a pipeline that can Since the specificity of the primers output through these MRPrimers has also been experimentally verified, they are used as a base algorithm for websites that help primer design, such as MRPrimerW and MRPrimerV.

그러나 MRPrimer 파이프라인은 대규모 DNA 서열 데이터베이스를 처리하기에는 계산 속도가 느리다는 약점이 있다. 실제로 MRPrimer는 101,684개의 사람 유전자 서열 데이터에 대해 당시 40대의 슈퍼컴퓨터를 활용했음에도 불구하고 2주 이상의 시간이 소요되었다. 시퀀싱 기술의 발달에 따라 서열 데이터베이스의 크기가 급격한 속도로 증가하고 있는 현재에 계산 속도의 한계는 장기적으로 더 큰 약점이 될 수 밖에 없다. 따라서 프라이머의 품질뿐 아니라 프라이머 디자인에 소요되는 속도 또한 매우 중요한 요소이다.However, the MRPrimer pipeline has a weakness in that it is computationally slow to process large DNA sequence databases. In fact, MRPrimer took more than two weeks for 101,684 human gene sequence data, despite using 40 supercomputers at the time. At present, when the size of sequence databases is rapidly increasing with the development of sequencing technology, the limitation of computational speed is bound to become a bigger weakness in the long term. Therefore, the speed required for primer design as well as the quality of primers is a very important factor.

한국등록특허 10-1666506호는 이러한 대규모 DNA 서열 데이터베이스에 대해 특이성 조건을 만족하는 유효한 모든 프라이머들을 디자인하는 방법에 관한 기술을 기재하고 있다.Korean Patent Registration No. 10-1666506 describes a method for designing all effective primers satisfying specificity conditions for such a large-scale DNA sequence database.

한국등록특허 10-1666506호Korean Patent Registration No. 10-1666506

본 실시예들은 상기 종래 기술에 따른 문제점들을 해결하기 위한 것으로, 주어진 대규모 서열 데이터베이스에 대해 사용자에 의해 주어진 여러 필터링 제약조건들을 만족하고 상동성 검사(Homology test)를 자체적으로 수행함으로써 그 특이성(Specificity)이 검증된 유효한 모든 프라이머 쌍들을 GPU를 활용하여 빠르고 효율적으로 디자인하는 방법을 제공함에 있다.The present embodiments are intended to solve the problems according to the prior art, and satisfy various filtering constraints given by the user for a given large-scale sequence database and perform a homology test on its own to determine its specificity. It is to provide a fast and efficient way to design all of these validated valid primer pairs using GPUs.

상기 종래 기술에서 언급한 문제점들에 대해 구체적인 해결 목적을 살펴보면, 먼저 종래에서의 문제인 프라이머에 대한 제약 조건을 검사함과 동시에 상동성 검사를 통한 특이성 검증 문제는 MRPrimer를 통해 해결할 수 있다.Looking at the specific solution to the problems mentioned in the prior art, first, the problem of specificity verification through homology inspection while examining the constraints on the primer, which is a problem in the prior art, can be solved through MRPrimer.

하지만 MRPrimer는 분산 기반의 파이프라인을 사용함으로써 각 머신간의 데이터 공유를 위해 불필요한 오버헤드(Overhead)를 유발할 수 있으며, 또한 MRPrimer는 대규모 DNA 서열 데이터를 기반으로 모든 가능한 프라이머에 대한 특이성 검사를 수행하기 위해 너무나 많은 시간을 필요로 한다는 문제점이 있다.However, MRPrimer uses a distribution-based pipeline, which can cause unnecessary overhead for data sharing between machines, and MRPrimer also uses large-scale DNA sequence data to perform specificity tests on all possible primers. The problem is that it takes too much time.

첫 번째 문제인 오버헤드를 줄이기 위해 본 실시예들은 분산 기반 시스템이 아닌 하나의 머신만을 사용하여 연산을 수행할 수 있다.In order to reduce overhead, which is the first problem, the present embodiments may perform calculations using only one machine rather than a distributed system.

또한, 상기 종래 기술에서의 두 번째 문제인 프라이머 디자인에 대한 속도의 한계를 해결하기 위해서 본 실시예들은 GPU의 병렬 연산의 특성과 빠른 연산 속도를 활용하여 보다 빠르고 효율적으로 프라이머를 디자인하며, 연산속도를 가속화 하기 위한 여러 가지 기법들을 활용할 수 있다. 하지만 GPU를 활용하는 것 또한 메인 메모리와 GPU 메모리 간의 데이터 복사 오버헤드 등이 존재하기 때문에 본 실시예들의 모든 과정에 대해서 GPU를 활용하지는 않고 가장 많은 시간이 소요되는 단계들에 대해서만 GPU를 활용하고, 그 외에의 단계에 대해서는 CPU의 멀티스레드(Multi-thread) 연산을 활용할 수 있다. In addition, in order to solve the second problem in the prior art, the speed limit for primer design, the present embodiments utilize the characteristics of parallel operation and fast operation speed of GPUs to design primers more quickly and efficiently, and increase the operation speed. Several techniques are available for acceleration. However, since using the GPU also involves data copy overhead between the main memory and the GPU memory, the GPU is not used for all the processes of the present embodiments, and the GPU is used only for the steps that take the most time, For other steps, the CPU's multi-thread operation can be utilized.

일 실시예에 따른 GPU를 활용하여 대규모 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 모든 프라이머들을 빠르게 디자인하는 장치는, GPU 프라이머를 활용하여 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 프라이머들을 디자인하기 위한 전체적인 연산을 수행하며, 연산 과정에서 생성하는 해쉬맵을 포함하는 데이터 구조는 메인 메모리에 저장하여 사용하고, 초기 입력으로 사용되는 상기 DNA 서열 데이터베이스 및 후보 프라이머들을 기록하는 중간과정의 파일의 경우 별도의 하드디스크에 파일 형태로 저장해두고 필요한 경우 읽어와 사용하는 CPU; 및 대규모 연산을 필요로 하는 경우에 상기 CPU를 통해 상기 GPU 프라이머의 일부 연산에 대한 명령을 전달 받아 구동되며, GPU 메모리는 상기 메인 메모리로부터 연산에 필요한 데이터를 복사 받아 커널 연산을 수행한 뒤 그 결과에 대해 상기 메인 메모리로 다시 복사하는 GPU를 포함하여 이루어질 수 있다. An apparatus for rapidly designing all valid primers that simultaneously satisfy primer restriction conditions and specificity conditions in a large-scale DNA sequence database by utilizing GPU according to an embodiment is a GPU primer to determine primer restriction conditions and specificity conditions in a DNA sequence database. The entire operation is performed to design effective primers that satisfy the same requirements, the data structure including the hash map generated during the operation is stored in the main memory, and the DNA sequence database and candidate primers used as initial input are recorded. In the case of a file in the middle process to be stored in the form of a file on a separate hard disk, the CPU reads and uses it if necessary; And when a large-scale operation is required, it is driven by receiving commands for some operations of the GPU primer through the CPU, and the GPU memory receives data necessary for operation from the main memory, performs kernel operation, and then performs kernel operation as a result. It can be made by including a GPU to copy back to the main memory for.

상기 CPU 및 상기 GPU를 통해 상기 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 프라이머들을 디자인하며, 상기 CPU에서 주어진 DNA 서열 데이터베이스와 싱글 프라이머 필터링(Single Primer Filtering) 조건 및 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 입력 받아, 최소길이와 최대길이 사이의 부분서열들을 추출하여 후보 프라이머들을 생성하여 출력하는 제1 단계; 출력된 상기 후보 프라이머들에 대해 입력 받은 상기 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여, 조건을 만족하는 프라이머들을 이용하여 연산에 사용될 데이터 구조인 해쉬맵을 생성하는 제2 단계; 추출된 상기 부분서열들을 기록한 C1' 파일과 상기 제2 단계를 통과해 상기 해쉬맵에 저장된 프라이머를 바탕으로 페어조인을 수행하여, 상기 프라이머가 5' 끝부분을 제외하고 나머지 부분이 동일한 경우, 상기 프라이머의 상기 해쉬맵 내의 valid 값을 업데이트 하는 제3 단계; 추출된 상기 부분서열들을 기록한 C1' 파일과 상기 싱글 프라이머 필터링(Single Primer Filtering) 및 5' Cross-Hybridization Filtering을 통과한 후보 프라이머 세트를 이용해 GPU 연산에서 사용할 데이터 구조를 생성하고, 상기 GPU 내에서 페어조인을 수행하여 각각의 후보 프라이머 세트에 있는 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지 부분이 동일한 경우, 상기 프라이머의 상기 해쉬맵 내의 valid 값을 업데이트 하는 제4 단계; 및 상기 제4 단계 결과에서 남아 있는 상기 프라이머를 정방향 프라이머와 역방향 프라이머 세트로 각각 나누어 각각에 대한 데이터 구조를 생성하고, 상기 GPU 내에서 셀프조인 연산을 수행하여 상기 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용하고, 조건을 만족한 프라이머 쌍에 대해 페널티 점수를 계산하여 출력하고, 같은 sidset 그룹 내에서 페널티 점수에 따라 순차 정렬하는 제5 단계를 수행할 수 있다. Design effective primers that simultaneously satisfy primer restriction conditions and specificity conditions in the DNA sequence database through the CPU and the GPU, and single primer filtering conditions and pair primer filtering with the DNA sequence database given by the CPU ( A first step of generating and outputting candidate primers by extracting subsequences between a minimum length and a maximum length by receiving conditions of Pair Primer Filtering; a second step of applying the single primer filtering condition received to the output candidate primers and generating a hash map, which is a data structure to be used for calculation, using primers satisfying the condition; Pair-joining is performed based on the C1' file recording the extracted subsequences and the primers stored in the hash map through the second step, and when the remaining parts of the primers are the same except for the 5' end, the A third step of updating a valid value in the hash map of the primer; A data structure to be used in GPU operation is created using the C1' file recording the extracted subsequences and a set of candidate primers that have passed the Single Primer Filtering and 5' Cross-Hybridization Filtering, and paired in the GPU. a fourth step of performing a join and updating valid values of the primers in the hash map when the primers in each candidate primer set are identical except for the given mismatch number (#mismatch); and dividing the remaining primers from the result of the fourth step into a forward primer and a reverse primer set, respectively, to create a data structure for each, and performing a self-join operation in the GPU to determine the Pair Primer Filtering condition. A fifth step of applying , calculating and outputting penalty scores for primer pairs satisfying the condition, and sequentially sorting according to the penalty scores within the same sidset group can be performed.

상기 CPU는, 상기 제1 단계에서 상기 DNA 데이터베이스를 서열 번호인 sid와 서열 데이터 S를 sid+S의 쌍의 형태로 입력 받고, 이후에 사용될 필터링 조건들을 입력 받아 모든 가능한 최소길이와 최대길이 사이의 상기 부분서열을 추출하여 후보 프라이머들을 생성하고, 출력된 상기 후보 프라이머들에 대해 역방향 상보적 프라이머를 만들어 역방향 프라이머를 표시하면 추출하며, 동일한 프라이머가 나타나는 sid의 집합인 sidset을 생성할 수 있다. The CPU, in the first step, receives the sequence number sid and the sequence data S in the form of a pair of sid + S from the DNA database, and receives the filtering conditions to be used later, and inputs the filtering conditions between all possible minimum lengths and maximum lengths. Candidate primers are generated by extracting the subsequence, reverse complementary primers are created for the output candidate primers, and reverse primers are extracted when displayed, and sidset, which is a set of sids in which the same primers appear, can be generated.

상기 CPU는, 상기 제2 단계에서 복수개의 상기 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여 조건을 만족하는 상기 프라이머에 대해서만 상기 해쉬맵을 생성하여 저장할 수 있다. The CPU may apply a plurality of single primer filtering conditions in the second step to generate and store the hash map only for the primers satisfying the condition.

상기 복수개의 싱글 프라이머 필터링(Single Primer Filtering) 조건은, 길이, 온도(

Figure 112020120544080-pat00001
, GC content(%), Self-Complementarity, 3' End Self-Complementary, 연속된 염기 및 end stability(G value)일 수 있다. The plurality of single primer filtering conditions are length, temperature (
Figure 112020120544080-pat00001
, GC content (%), Self-Complementarity, 3' End Self-Complementary, consecutive bases, and end stability (G value).

상기 GPU는, 상기 제4 단계에서 생성된 상기 GPU 연산에서 사용할 데이터 구조를 복사하여 arraysC1과 arraysC3의 페어조인을 수행하면서 각각의 세트 내의 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지가 동일한 경우, arraysC3의 프라이머에 대해 '타당하지 않음'을 나타내도록 업데이트 할 수 있다.The GPU copies the data structure to be used in the GPU operation generated in the fourth step and performs a pair join of arraysC1 and arraysC3, and the primers in each set are the same except for the number of mismatches (#mismatch) given, It can be updated to indicate 'not valid' for the primers in arraysC3.

상기 GPU는, 상기 제5 단계에서 생성된 정방향 프라이머와 역방향 프라이머 세트로 각각 나누어 각각에 대한 데이터 구조를 복사하여 상기 GPU 내에서 같은 sid 내의 정방향 프라이머와 역방향 프라이머 사이의 페어조인 연산을 수행하며, 복수개의 상기 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용해 조건을 만족하는 프라이머에 대해서만 상기 페널티 점수를 계산하여 저장하고, 상기 페널티 점수가 저장된 데이터 구조를 상기 메인 메모리로 복사해 결과물을 출력할 수 있다. The GPU divides each of the forward primer and reverse primer sets generated in the fifth step, copies the data structure for each, and performs a pair-join operation between the forward primer and the reverse primer within the same sid in the GPU, The penalty score is calculated and stored only for primers that satisfy the condition by applying the Pair Primer Filtering condition, and the data structure in which the penalty score is stored is copied to the main memory to output the result. .

다른 실시예에 따른 컴퓨터 장치를 통해 구현되는 GPU를 활용하여 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 프라이머들을 디자인하는 방법은, 주어진 DNA 서열 데이터베이스와 싱글 프라이머 필터링(Single Primer Filtering) 조건 및 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 입력 받아, 최소길이와 최대길이 사이의 부분서열들을 추출하여 후보 프라이머들을 생성하여 출력하는 제1 단계; 출력된 상기 후보 프라이머들에 대해 입력 받은 상기 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여, 조건을 만족하는 프라이머들을 이용하여 연산에 사용될 데이터 구조인 해쉬맵을 생성하는 제2 단계; 추출된 상기 부분서열들을 기록한 C1' 파일과 상기 제2 단계를 통과해 상기 해쉬맵에 저장된 프라이머를 바탕으로 페어조인을 수행하여, 상기 프라이머가 5' 끝부분을 제외하고 나머지 부분이 동일한 경우, 상기 프라이머의 상기 해쉬맵 내의 valid 값을 업데이트 하는 제3 단계; 추출된 상기 부분서열들을 기록한 C1' 파일과 상기 싱글 프라이머 필터링(Single Primer Filtering) 및 5' Cross-Hybridization Filtering을 통과한 후보 프라이머 세트를 이용해 GPU 연산에서 사용할 데이터 구조를 생성하고, GPU 내에서 페어조인을 수행하여 각각의 후보 프라이머 세트에 있는 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지 부분이 동일한 경우, 상기 프라이머의 상기 해쉬맵 내의 valid 값을 업데이트 하는 제4 단계; 및 상기 제4 단계 결과에서 남아 있는 상기 프라이머를 정방향 프라이머와 역방향 프라이머 세트로 각각 나누어 각각에 대한 데이터 구조를 생성하고, 상기 GPU 내에서 셀프조인 연산을 수행하여 상기 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용하고, 조건을 만족한 프라이머 쌍에 대해 페널티 점수를 계산하여 출력하고, 같은 sidset 그룹 내에서 페널티 점수에 따라 순차 정렬하는 제5 단계를 포함하여 이루어질 수 있다. A method for designing effective primers that simultaneously satisfy primer restriction conditions and specificity conditions in a DNA sequence database using a GPU implemented through a computer device according to another embodiment is a given DNA sequence database and single primer filtering (Single Primer Filtering) A first step of generating and outputting candidate primers by extracting subsequences between a minimum length and a maximum length by receiving input conditions and pair primer filtering conditions; a second step of applying the single primer filtering condition received to the output candidate primers and generating a hash map, which is a data structure to be used for calculation, using primers satisfying the condition; Pair-joining is performed based on the C1' file recording the extracted subsequences and the primers stored in the hash map through the second step, and when the remaining parts of the primers are the same except for the 5' end, the A third step of updating a valid value in the hash map of the primer; A data structure to be used in GPU operation is created using the C1' file recording the extracted subsequences and a set of candidate primers that have passed the Single Primer Filtering and 5' Cross-Hybridization Filtering, and pair-joined in the GPU. A fourth step of updating the valid value of the primers in the hash map when the primers in each candidate primer set are the same except for the given number of mismatches (#mismatch) by performing; and dividing the remaining primers from the result of the fourth step into a forward primer and a reverse primer set, respectively, to create a data structure for each, and performing a self-join operation in the GPU to determine the Pair Primer Filtering condition. A fifth step of applying , calculating and outputting penalty scores for primer pairs satisfying the condition, and sequentially sorting according to the penalty scores within the same sidset group.

상기 제1 단계는, 상기 DNA 데이터베이스를 서열 번호인 sid와 서열 데이터 S를 sid+S의 쌍의 형태로 입력 받고, 이후에 사용될 필터링 조건들을 입력 받아 모든 가능한 최소길이와 최대길이 사이의 상기 부분서열을 추출하여 후보 프라이머들을 생성하는 단계; 및 출력된 상기 후보 프라이머들에 대해 역방향 상보적 프라이머를 만들어 역방향 프라이머를 표시하면 추출하는 단계를 포함하고, 동일한 프라이머가 나타나는 sid의 집합인 sidset을 생성할 수 있다. In the first step, the DNA database receives the sequence number sid and the sequence data S in the form of a pair of sid + S, receives the filtering conditions to be used later, and receives all possible minimum and maximum lengths of the subsequence Extracting and generating candidate primers; and making reverse complementary primers for the output candidate primers, and extracting the reverse primers if indicated, and generating a sidset, which is a set of sids in which the same primers appear.

상기 제2 단계는, 복수개의 상기 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여 조건을 만족하는 상기 프라이머에 대해서만 상기 해쉬맵을 생성하여 저장할 수 있다. In the second step, a plurality of single primer filtering conditions may be applied to generate and store the hash map only for the primers satisfying the condition.

상기 복수개의 싱글 프라이머 필터링(Single Primer Filtering) 조건은, 길이, 온도(

Figure 112020120544080-pat00002
, GC content(%), Self-Complementarity, 3' End Self-Complementary, 연속된 염기 및 end stability(G value)일 수 있다. The plurality of single primer filtering conditions are length, temperature (
Figure 112020120544080-pat00002
, GC content (%), Self-Complementarity, 3' End Self-Complementary, consecutive bases, and end stability (G value).

상기 제3 단계는, 주어진 DNA 서열 데이터베이스에서 추출된 모든 가능한 상기 부분서열이 저장된 C1' 파일과 상기 싱글 프라이머 필터링(Single Primer Filtering)을 통과한 후보 프라이머가 저장된 상기 해쉬맵으로부터 페어조인을 수행하여, 각 세트의 프라이머가 5' 끝부분을 제외하고 나머지 부분이 동일한 경우, 상기 해쉬맵에 저장된 프라이머가 '타당하지 않음'을 나타내도록 업데이트 할 수 있다. In the third step, a pair join is performed from the C1' file in which all possible subsequences extracted from a given DNA sequence database are stored and the hash map in which candidate primers that have passed the single primer filtering are stored, If the primers of each set are identical except for the 5' end, the primers stored in the hash map may be updated to indicate 'not valid'.

상기 제4 단계는, 싱글 프라이머 필터링(Single Primer Filtering)과 5' Cross-Hybridization Filtering을 모두 통과한 프라이머가 저장된 해쉬맵으로부터 프라이머를 여러 개의 시드(Seed)로 나누어 또 다른 해쉬맵을 생성하는 단계; 상기 또 다른 해쉬맵으로부터 상기 싱글 프라이머 필터링(Single Primer Filtering) 및 5' Cross-Hybridization Filtering을 모두 통과한 프라이머에 대한 정보를 가지는 데이터 구조 arraysC3와 주어진 DNA 서열 데이터베이스에 추출된 모든 가능한 부분서열에 대한 정보를 가지는 데이터 구조 arraysC1을 생성하는 단계; 및 생성한 데이터 구조를 상기 GPU에 복사하여 arraysC1과 arraysC3의 페어조인을 수행하면서 각각의 세트 내의 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지가 동일한 경우, arraysC3의 프라이머에 대해 '타당하지 않음'을 나타내도록 업데이트 하는 단계를 포함할 수 있다. In the fourth step, generating another hash map by dividing the primers into several seeds from the hash map in which the primers that have passed both Single Primer Filtering and 5' Cross-Hybridization Filtering are stored; Data structure arraysC3 having information on primers that have passed both the Single Primer Filtering and 5' Cross-Hybridization Filtering from the another hash map and information on all possible subsequences extracted from a given DNA sequence database Creating a data structure arraysC1 having; And copying the generated data structure to the GPU to perform a pair join of arraysC1 and arraysC3, and when the primers in each set are the same except for the given number of mismatches (#mismatch), 'not valid' for the primers in arraysC3 It may include updating to indicate.

상기 제5 단계는, 동일한 sid를 가지는 후보 프라이머를 그룹화하여 프라이머 개수가 작은 순으로 정렬하는 단계; 정렬한 파일을 입력으로 받아 후보 프라이머를 DNA 서열 데이터베이스에서 추출할 때 수행했던 표시의 유무에 따라 정방향 프라이머와 역방향 프라이머 두 세트로 분리하여 각각에 대해 GPU 연산에 사용될 데이터 구조를 생성하고 페널티 점수를 저장할 수 있는 데이터 구조를 생성하는 단계; 생성된 상기 데이터 구조를 상기 GPU에 복사하여 상기 GPU 내에서 같은 sid 내의 정방향 프라이머와 역방향 프라이머 사이의 페어조인 연산을 수행하며 복수개의 상기 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용해 조건을 만족하는 프라이머에 대해서만 상기 페널티 점수를 계산하여 저장하는 단계; 및 상기 페널티 점수가 저장된 데이터 구조를 메인 메모리로 복사해 결과물을 출력하고 동일한 sidset을 기준으로 그룹화 하여, 각 sidset에서 상기 페널티 점수를 이용해 프라이머 쌍의 순서를 부여해 정렬하는 단계를 포함할 수 있다. The fifth step may include grouping candidate primers having the same sid and arranging them in descending order of the number of primers; Receives the sorted file as an input and separates the candidate primers into two sets of forward and reverse primers according to the presence or absence of the mark performed when extracting the candidate primers from the DNA sequence database, creates a data structure to be used for GPU operation for each set, and stores penalty scores. Creating a data structure that can be; Copy the generated data structure to the GPU, perform a pair-join operation between forward primers and reverse primers within the same sid in the GPU, and apply a plurality of the pair primer filtering conditions to satisfy the condition calculating and storing the penalty score only for the primer; and copying the data structure in which the penalty score is stored to a main memory, outputting the result, grouping based on the same sidset, and assigning an order to primer pairs using the penalty score in each sidset.

상기 복수개의 쌍 프라이머 필터링(Pair Primer Filtering) 조건은, 길이 차이, 온도 차이, 생성물의 길이, Pair-Complementary 및 3' End Pair-Complementary를 포함할 수 있다. The plurality of pair primer filtering conditions may include length difference, temperature difference, product length, Pair-Complementary, and 3' End Pair-Complementary.

실시예들에 따르면 주어진 대규모 DNA 서열 데이터베이스에 대해 사용자에 의해 주어진 여러 필터링 제약조건을 만족하고, 그 특이성이 검증된 유효한 모든 커버리지의 프라이머 쌍들을 GPU를 활용하여 빠르게 디자인할 수 있다. According to the embodiments, it is possible to quickly design primer pairs of all valid coverages that satisfy various filtering constraints given by the user for a given large-scale DNA sequence database and whose specificity has been verified using a GPU.

또한, 실시예들에 따르면 프라이머 디자인을 싱글/쌍 프라이머 필터링(Single/Pair Primer Filtering) 조건과 상동성 테스트(Homology Test)를 하나의 통합된 방법으로 검사하여 사용자가 추가의 툴을 사용하지 않아도 되기 때문에 유효성을 확인하는 과정에서 실수가 발생하지 않으며 효율적으로 프라이머를 디자인할 수 있다. In addition, according to the embodiments, the primer design is checked for Single / Pair Primer Filtering conditions and the homology test in one integrated method, so that the user does not have to use additional tools. Therefore, mistakes do not occur in the validation process and primers can be designed efficiently.

도 1은 일반적인 정방향 프라이머(Forward Primer)와 역방향 프라이머(Reverse Primer)가 DNA 표적서열에 결합된 상태를 나타내는 도면이다.
도 2는 일 실시예에 따른 시스템 구성도를 나타내는 도면이다.
도 3은 일 실시예들에 따른 GPU를 활용하여 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 프라이머들을 디자인하는 방법을 나타내는 흐름도이다.
도 4는 일 실시예에 따른 후보 프라이머 추출 방법을 나타내는 흐름도이다.
도 5는 일 실시예에 따른 C1 파일 및 C1' 파일의 예시를 나타내는 도면이다.
도 6은 일 실시예에 따른 싱글 프라이머 필터링(Single Primer Filtering) 조건을 만족하는 프라이머에 대한 해쉬맵 생성 방법을 나타내는 흐름도이다.
도 7은 일 실시예에 따른 5' Cross-Hybridization Filtering 방법을 나타내는 흐름도이다.
도 8은 일 실시예에 따른 {seedH, arraysC1, arraysC3} 생성 및 General Cross-Hybridization Filtering 방법을 나타내는 흐름도이다.
도 9는 일 실시예에 따른 {seedH, arraysC1, arraysC3} 생성 및 General Cross-Hybridization Filtering의 예시를 나타내는 도면이다.
도 10은 일 실시예에 따른 {seedH, arraysC1, arraysC3} 생성 및 General Cross-Hybridization Filtering 방법에서의 데이터 흐름과 타임라인에 대한 예시를 나타내는 도면이다.
도 11은 일 실시예에 따른 Pair Filtering 및 Scoring 방법을 나타내는 흐름도이다.
도 12는 일 실시예에 따른 프라이머 순차 정렬 방법의 예시를 나타내는 도면이다.
1 is a view showing a state in which a general forward primer and a reverse primer are bound to a DNA target sequence.
2 is a diagram showing a system configuration diagram according to an embodiment.
3 is a flowchart illustrating a method of designing effective primers that simultaneously satisfy primer restriction conditions and specificity conditions in a DNA sequence database using a GPU according to an embodiment.
4 is a flowchart illustrating a method of extracting candidate primers according to an embodiment.
5 is a diagram illustrating examples of a C1 file and a C1' file according to an embodiment.
6 is a flowchart illustrating a method for generating a hash map for primers satisfying a single primer filtering condition according to an embodiment.
7 is a flowchart illustrating a 5' Cross-Hybridization Filtering method according to an embodiment.
8 is a flowchart illustrating a method of generating {seedH, arraysC1, arraysC3} and general cross-hybridization filtering according to an embodiment.
9 is a diagram illustrating an example of generating {seedH, arraysC1, arraysC3} and general cross-hybridization filtering according to an embodiment.
10 is a diagram illustrating an example of a data flow and a timeline in a method of generating {seedH, arraysC1, arraysC3} and general cross-hybridization filtering according to an embodiment.
11 is a flowchart illustrating a pair filtering and scoring method according to an embodiment.
12 is a diagram illustrating an example of a primer sequence alignment method according to an embodiment.

이하, 첨부된 도면을 참조하여 실시예들을 설명한다. 그러나, 기술되는 실시예들은 여러 가지 다른 형태로 변형될 수 있으며, 본 발명의 범위가 이하 설명되는 실시예들에 의하여 한정되는 것은 아니다. 또한, 여러 실시예들은 당해 기술분야에서 평균적인 지식을 가진 자에게 본 발명을 더욱 완전하게 설명하기 위해서 제공되는 것이다. 도면에서 요소들의 형상 및 크기 등은 보다 명확한 설명을 위해 과장될 수 있다.Hereinafter, embodiments will be described with reference to the accompanying drawings. However, the described embodiments may be modified in many different forms, and the scope of the present invention is not limited by the embodiments described below. In addition, several embodiments are provided to more completely explain the present invention to those skilled in the art. The shapes and sizes of elements in the drawings may be exaggerated for clarity.

아래의 실시예들은 주어진 대규모 DNA 서열 데이터베이스에 대해 사용자에 의해 주어진 여러 필터링 제약조건들을 만족하고 상동성 검사(Homology test)를 자체적으로 수행함으로써 그 특이성(Specificity)이 검증된 유효한 모든 프라이머 쌍들을 GPU를 활용하여 빠르게 고 효율적으로 디자인하는 방법 및 장치를 제공한다.The following examples satisfy various filtering constraints given by the user for a given large-scale DNA sequence database and perform a homology test on its own to find all valid primer pairs whose specificity has been verified by GPU. Provides a method and device for designing quickly and efficiently using

본 실시예들의 실험 결과, 사람 및 쥐 등을 포함한 여섯 종의 138,375 개의 전체 mRNA RefSeq(NCBI Reference Sequence) 데이터에 대한 실험을 통하여, 총 816,034,287 개의 프라이머 쌍을 디자인하였다.As a result of the experiments of these examples, a total of 816,034,287 primer pairs were designed through experiments on 138,375 total mRNA RefSeq (NCBI Reference Sequence) data from six species, including humans and mice.

상기 결과에 대해 보다 상세히 서술하자면 51,979 개의 사람 mRNA 서열 데이터에 대해 278,147,461 개의 프라이머 쌍을 디자인하였고, 35,349 개의 쥐 mRNA 서열 데이터에 대해 234,410,464 개의 프라이머 쌍을 디자인하였다.To describe the above results in more detail, 278,147,461 primer pairs were designed for 51,979 human mRNA sequence data, and 234,410,464 primer pairs were designed for 35,349 mouse mRNA sequence data.

GPU 활용의 효율성 측면에서 본 실시예들은 사람 RefSeq 서열 데이터베이스에서 모든 가능한 프라이머 쌍들을 디자인하는데 4 개의 NVIDIA GTX 1080ti GPU를 보유한 한대의 머신을 사용했을 때 2 시간 안에 모든 프라이머 쌍을 디자인하는 것이 가능하기 때문에 매우 효과적이다. 또한, 상기 언급된 138,375 개의 전체 데이터베이스에 대한 모든 가능한 프라이머 쌍들을 디자인하는 데에도 동일한 머신을 사용하였을 때 4~5 시간 안에 디자인이 가능하다.In terms of efficiency of GPU utilization, the present examples show that it is possible to design all possible primer pairs in a human RefSeq sequence database in 2 hours when using a single machine with 4 NVIDIA GTX 1080ti GPUs to design all possible primer pairs. Very effective. In addition, when the same machine is used to design all possible primer pairs for the above-mentioned 138,375 entire databases, it is possible to design within 4 to 5 hours.

본 실시예들로 디자인한 프라이머 쌍들에 대해서는 페널티 점수가 계산되어 각 sidset 내에서 이 페널티 점수들을 바탕으로 순차 정렬되어 있기 때문에, 특정 표적 서열을 포함하는 sidset에 대한 최적의 프라이머 쌍 하나, 또는 원하는 순위까지의 프라이머 쌍 등을 쉽게 찾을 수 있어 실제로 실험에 활용하는 데에 있어 효율적이다.Since penalty scores are calculated for the primer pairs designed in these examples and sequentially aligned based on these penalty scores within each sidset, one optimal primer pair for a sidset containing a specific target sequence, or a desired rank Primer pairs up to can be easily found, so it is efficient to actually use them in experiments.

본 실시예들은 완전한 프라이머 쌍들을 디자인하기 때문에, 필터링 조건만 동일하게 유지된다면 주어진 입력 서열에 대한 모든 프라이머 쌍들의 결과를 바탕으로 데이터베이스를 구축하여 PCR 실험에 반복적으로 사용할 수 있다. 일반적으로 실험실에서 사용되는 필터링 조건은 바뀌는 일이 드물기 때문에 원하는 종에 대한 서열 데이터베이스나 특정 서열 데이터베이스에 대해 한번만 프로그램을 실행시키고 그 결과를 바탕으로 데이터베이스를 구축함으로써 해당 실험실에 적합한 최적의 프라이머 데이터베이스를 구축할 수 있다.Since the present examples design complete primer pairs, a database based on the results of all primer pairs for a given input sequence can be constructed and used repeatedly in PCR experiments, provided that the filtering conditions remain the same. In general, since the filtering conditions used in laboratories rarely change, an optimal primer database suitable for the laboratory is constructed by executing the program only once for the sequence database for the desired species or for a specific sequence database and building the database based on the results. can do.

뿐만 아니라, 본 실시예들은 모든 가능한 조합을 찾기 위해 페어조인을 수행함으로써 데이터의 규모가 커짐에 따라 연산량이 지수적으로 증가할 수 있음에도 불구하고 GPU의 병렬 연산의 특성과 빠른 연산속도를 활용하여 빠른 프라이머 디자인이 가능하기 때문에 추후에 입력 서열 데이터베이스가 업데이트 되어 더 큰 데이터베이스에 대해 연산을 수행해야 하더라도 빠르게 결과를 얻을 수 있다. In addition, the present embodiments perform pair join to find all possible combinations, so that the amount of computation can increase exponentially as the size of data increases. Since primer design is possible, results can be obtained quickly even if the input sequence database is updated later and calculations must be performed on a larger database.

이하, 본 실시예들에 따른 GPU를 활용하여 대규모 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 모든 프라이머들을 빠르게 디자인하는 방법 및 장치에 대해 상세하게 설명해 보기로 한다.Hereinafter, a method and apparatus for quickly designing all effective primers that simultaneously satisfy primer restriction conditions and specificity conditions in a large-scale DNA sequence database by utilizing the GPU according to the present embodiments will be described in detail.

도 2는 일 실시예에 따른 시스템 구성도를 나타내는 도면이다.2 is a diagram showing a system configuration diagram according to an embodiment.

도 2를 참조하면, 본 실시예들을 구현하기 위한 시스템 구성도를 나타내며, GPU 프라이머(GPU Primer: G-Primer)(101)는 CPU(102) 및 GPU(103)를 포함할 수 있고, 실시예에 따라 CPU(102) 및 GPU(103)는 메모리(104, 105)를 포함할 수 있다. Referring to FIG. 2, a system configuration diagram for implementing the present embodiments is shown, and a GPU Primer (G-Primer) 101 may include a CPU 102 and a GPU 103, Accordingly, the CPU 102 and GPU 103 may include memories 104 and 105 .

보다 구체적으로 GPU 프라이머(101) 프로그램은 CPU(102)와 GPU(103)를 모두 활용하여 동작하며, GPU 프라이머(101)를 구동하기 위한 CPU(102)와 GPU(103), 그리고 메인 메모리(104) 및 하드디스크(106)를 포함할 수 있다. 또한, GPU(103) 각각은 메모리(105)를 포함하여 구성될 수 있다.More specifically, the GPU primer 101 program operates by utilizing both the CPU 102 and the GPU 103, the CPU 102 and the GPU 103 for driving the GPU primer 101, and the main memory 104 ) and a hard disk 106. In addition, each of the GPUs 103 may include a memory 105 .

CPU(102) 및 GPU(103)를 통해 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 프라이머들을 디자인할 수 있다. 상기 GPU 프라이머(101) 프로그램의 구체적인 실행 순서는 도 3을 참조하여 예를 들어 설명할 수 있다. Through the CPU 102 and the GPU 103, it is possible to design effective primers that simultaneously satisfy primer restriction conditions and specificity conditions in the DNA sequence database. A specific execution sequence of the GPU primer 101 program can be described as an example with reference to FIG. 3 .

도 3에서의 전체적인 연산은, 도 2에 도시된 CPU(102)를 활용하여 수행되며, 연산 과정에서 생성하는 해쉬맵 등의 데이터 구조는 메인 메모리(104)에 저장하여 사용하고, 그 외에 초기 입력으로 사용되는 DNA 서열 데이터베이스 및 후보 프라이머를 기록하는 중간과정의 파일의 경우 하드디스크(106)에 파일 형태로 저장해두고 필요한 경우 이를 읽어와 사용할 수 있다. 여기서, GPU(105)의 경우 대규모 연산을 필요로 하는 일부 단계(S306, S310)에서만 사용될 수 있다. The overall operation in FIG. 3 is performed by utilizing the CPU 102 shown in FIG. 2, and data structures such as hash maps generated in the operation process are stored in the main memory 104 and used, and other initial inputs In the case of files in the intermediate process for recording the DNA sequence database and candidate primers used as a file, they can be stored in the hard disk 106 in the form of files and read and used if necessary. Here, the GPU 105 may be used only in some steps (S306 and S310) requiring large-scale calculations.

GPU(103)는 기본적으로 CPU(102)를 통해 GPU 프라이머(101)의 일부 연산에 대한 명령을 전달 받아 구동되며, GPU 메모리(105)는 메인 메모리(104)로부터 연산에 필요한 데이터를 복사 받아 GPU 내에서의 커널 연산을 수행한 뒤 그 결과에 대해 메인 메모리(104)로 다시 복사할 수 있다.The GPU 103 is basically driven by receiving commands for some operations of the GPU primer 101 through the CPU 102, and the GPU memory 105 receives data necessary for operation from the main memory 104 and is copied to the GPU. After performing a kernel operation in the internal memory 104, the result may be copied back to the main memory 104.

예를 들어, CPU(102)는 제1 단계에서 DNA 데이터베이스를 서열 번호인 sid와 서열 데이터 S를 sid+S의 쌍의 형태로 입력 받고, 이후에 사용될 필터링 조건들을 입력 받아 모든 가능한 최소길이와 최대길이 사이의 부분서열을 추출하여 후보 프라이머들을 생성하고, 출력된 후보 프라이머들에 대해 역방향 상보적 프라이머를 만들어 역방향 프라이머를 표시하면 추출하며, 동일한 프라이머가 나타나는 sid의 집합인 sidset을 생성할 수 있다. For example, in the first step, the CPU 102 receives the sequence number sid and the sequence data S in the form of a pair of sid + S from the DNA database, and inputs the filtering conditions to be used thereafter to obtain all possible minimum and maximum lengths. Candidate primers can be generated by extracting subsequences between the lengths, reverse complementary primers are created for the output candidate primers, and reverse primers are extracted when displayed, and sidset, which is a set of sids in which the same primers appear, can be generated.

또한, CPU(102)는 제2 단계에서 복수개의 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여 조건을 만족하는 프라이머에 대해서만 해쉬맵을 생성하여 저장할 수 있다. In addition, the CPU 102 may apply a plurality of single primer filtering conditions in the second step to generate and store a hash map only for primers that satisfy the conditions.

GPU(103)는 제4 단계에서 생성된 GPU 연산에서 사용할 데이터 구조를 복사하여 arraysC1과 arraysC3의 페어조인을 수행하면서 각각의 세트 내의 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지가 동일한 경우, arraysC3의 프라이머에 대해 '타당하지 않음'을 나타내도록 업데이트 할 수 있다.The GPU 103 copies the data structure to be used in the GPU operation generated in the fourth step and performs a pair join of arraysC1 and arraysC3, and when the primers in each set are the same except for the number of mismatches (#mismatch) given, arraysC3 can be updated to indicate 'not valid' for the primers in

또한, GPU(103)는 제5 단계에서 생성된 정방향 프라이머와 역방향 프라이머 세트로 각각 나누어 각각에 대한 데이터 구조를 복사하여 GPU(103) 내에서 같은 sid 내의 정방향 프라이머와 역방향 프라이머 사이의 페어조인 연산을 수행하며, 복수개의 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용해 조건을 만족하는 프라이머에 대해서만 페널티 점수를 계산하여 저장하고, 페널티 점수가 저장된 데이터 구조를 메인 메모리로 복사해 결과물을 출력할 수 있다. In addition, the GPU 103 divides each of the forward primer and reverse primer sets generated in the fifth step, copies the data structure for each, and performs a pair-join operation between the forward primer and the reverse primer within the same sid in the GPU 103 , apply a plurality of pair primer filtering conditions, calculate and store penalty scores only for primers that satisfy the conditions, and copy the data structure in which the penalty scores are stored to the main memory to output the result. .

일 실시예에 따른 컴퓨터 장치를 통해 구현되는 GPU(103)를 활용하여 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 프라이머들을 디자인하는 방법은, 주어진 DNA 서열 데이터베이스와 싱글 프라이머 필터링(Single Primer Filtering) 조건 및 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 입력 받아, 최소길이와 최대길이 사이의 부분서열들을 추출하여 후보 프라이머들을 생성하여 출력하는 제1 단계, 출력된 후보 프라이머들에 대해 입력 받은 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여, 조건을 만족하는 프라이머들을 이용하여 연산에 사용될 데이터 구조인 해쉬맵을 생성하는 제2 단계, 추출된 부분서열들을 기록한 C1' 파일과 제2 단계를 통과해 해쉬맵에 저장된 프라이머를 바탕으로 페어조인을 수행하여, 프라이머가 5' 끝부분을 제외하고 나머지 부분이 동일한 경우, 프라이머의 해쉬맵 내의 valid 값을 업데이트 하는 제3 단계, 추출된 부분서열들을 기록한 C1' 파일과 싱글 프라이머 필터링(Single Primer Filtering) 및 5' Cross-Hybridization Filtering을 통과한 후보 프라이머 세트를 이용해 GPU(103) 연산에서 사용할 데이터 구조를 생성하고, GPU(103) 내에서 페어조인을 수행하여 각각의 후보 프라이머 세트에 있는 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지 부분이 동일한 경우, 프라이머의 해쉬맵 내의 valid 값을 업데이트 하는 제4 단계, 및 제4 단계 결과에서 남아 있는 프라이머를 정방향 프라이머와 역방향 프라이머 세트로 각각 나누어 각각에 대한 데이터 구조를 생성하고, GPU(103) 내에서 셀프조인 연산을 수행하여 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용하고, 조건을 만족한 프라이머 쌍에 대해 페널티 점수를 계산하여 출력하고, 같은 sidset 그룹 내에서 페널티 점수에 따라 순차 정렬하는 제5 단계를 포함하여 이루어질 수 있다. A method for designing effective primers that simultaneously satisfy primer restriction conditions and specificity conditions in a DNA sequence database by utilizing the GPU 103 implemented through a computer device according to an embodiment is a given DNA sequence database and single primer filtering (Single Primer Filtering). The first step of generating and outputting candidate primers by extracting subsequences between the minimum and maximum lengths by receiving Primer Filtering conditions and Pair Primer Filtering conditions. A second step of generating a hash map, which is a data structure to be used for calculation, by applying a Single Primer Filtering condition and using primers that satisfy the condition, and a C1' file recording the extracted subsequences and the second step Pass through and perform pair-join based on the primers stored in the hash map, and if the remaining parts of the primers are the same except for the 5' end, the third step of updating the valid value in the hash map of the primers, the extracted subsequences Using the recorded C1' file and a set of candidate primers that have passed Single Primer Filtering and 5' Cross-Hybridization Filtering, a data structure to be used in GPU (103) operation is created, and pair join is performed in GPU (103). When the primers in each candidate primer set are the same except for the given number of mismatches (#mismatch), the fourth step of updating the valid value in the hash map of the primer, and the remaining primers from the result of the fourth step Divided into forward and reverse primer sets, a data structure for each is created, a self-join operation is performed in the GPU 103 to apply pair primer filtering conditions, and primer pairs that satisfy the conditions are applied. Calculate and output penalty points for the same sidset A fifth step of sequentially sorting according to penalty points within the group may be included.

제1 단계는, CPU(102)에서 DNA 데이터베이스를 서열 번호인 sid와 서열 데이터 S를 sid+S의 쌍의 형태로 입력 받고, 이후에 사용될 필터링 조건들을 입력 받아 모든 가능한 최소길이와 최대길이 사이의 부분서열을 추출하여 후보 프라이머들을 생성하는 단계, 및 출력된 후보 프라이머들에 대해 역방향 상보적 프라이머를 만들어 역방향 프라이머를 표시하면 추출하는 단계를 포함하고, 동일한 프라이머가 나타나는 sid의 집합인 sidset을 생성할 수 있다. 예를 들어, CPU(102)는 DNA 데이터베이스를 서열 번호인 sid와 서열 데이터 S를 파일 형태로 입력 받아 모든 가능한 최소길이와 최대길이 사이의 모든 후보 프라이머의 부분서열을 추출하여

Figure 112020120544080-pat00003
의 형태로 C1 파일을 생성하고, 이후에 같은 프라이머가 나타나는 sid의 집합으로 sidset를 생성하고
Figure 112020120544080-pat00004
형태로 추출하여 C1' 파일을 생성할 수 있다.In the first step, the CPU 102 receives the sequence number sid and the sequence data S in the form of a pair of sid + S from the CPU 102, receives filtering conditions to be used later, generating candidate primers by extracting subsequences, and generating reverse complementary primers for the output candidate primers, and extracting the reverse primers when indicated, and generating sidset, which is a set of sids in which the same primers appear. can For example, the CPU 102 receives a DNA database as a sequence number sid and sequence data S in the form of a file, extracts subsequences of all candidate primers between all possible minimum lengths and maximum lengths, and
Figure 112020120544080-pat00003
Create a C1 file in the form of , then create a sidset as a set of sids in which the same primer appears,
Figure 112020120544080-pat00004
You can create a C1' file by extracting it in the form.

제2 단계는, CPU(102)에서 복수개의 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여 조건을 만족하는 프라이머에 대해서만 해쉬맵을 생성하여 저장할 수 있다. 예를 들어, CPU(102)는 C1 파일을 읽으면서 복수개의 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여 조건을 만족하는 프라이머에 대해서만 primerH와 suffixH 해쉬맵을 생성하고, 싱글 프라이머 필터링(Single Primer Filtering) 조건을 만족한 프라이머만 출력하여 C2 파일을 생성할 수 있다. 여기서, 복수개의 싱글 프라이머 필터링(Single Primer Filtering) 조건은, 길이, 온도(

Figure 112020120544080-pat00005
, GC content(%), Self-Complementarity, 3' End Self-Complementary, 연속된 염기 및 end stability(G value)일 수 있다. In the second step, a hash map may be generated and stored only for primers satisfying the condition by applying a plurality of single primer filtering conditions in the CPU 102 . For example, the CPU 102 applies a plurality of single primer filtering conditions while reading the C1 file, generates primerH and suffixH hash maps only for primers that satisfy the conditions, and single primer filtering (Single Primer Filtering) A C2 file can be created by outputting only the primers that satisfy the filtering conditions. Here, the plurality of single primer filtering conditions are the length, temperature (
Figure 112020120544080-pat00005
, GC content (%), Self-Complementarity, 3' End Self-Complementary, consecutive bases, and end stability (G value).

제3 단계는, CPU(102)에서 주어진 DNA 서열 데이터베이스에서 추출된 모든 가능한 부분서열이 저장된 C1' 파일과 싱글 프라이머 필터링(Single Primer Filtering)을 통과한 후보 프라이머가 저장된 해쉬맵으로부터 페어조인을 수행하여, 각 세트의 프라이머가 5' 끝부분을 제외하고 나머지 부분이 동일한 경우, 해쉬맵에 저장된 프라이머가 '타당하지 않음'을 나타내도록 업데이트 할 수 있다. 예를 들어, CPU(102)는 주어진 DNA 데이터베이스에서 추출된 모든 가능한 후보 프라이머를 포함하고 있는 C1' 파일과 싱글 프라이머 필터링(Single Primer Filtering)을 통과한 프라이머들을 바탕으로 생성된 suffixH, 두 개를 바탕으로 동일한 suffix를 가지는 프라이머들 간에 페어조인을 수행하면서, C1'의 프라이머와 suffixH 내의 프라이머가 5' 끝부분을 제외하고 나머지 부분이 똑같은 동시에 다른 sidset을 가지는 경우, 해당 프라이머에 대해 primerH에서 valid를 '타당하지 않음'을 뜻하는 '0'으로 설정할 수 있다. C1'의 프라이머와 suffixH 내의 프라이가 5' 끝부분을 제외하고 동일한 매우 높은 유사도를 가짐에도 불구하고 다른 sidset을 가지는 것은 해당 프라이머가 비표적 서열 또한 증폭시킬 수 있음을 뜻하기 때문에 이는 제거되어야 한다.In the third step, the CPU 102 performs a pair join from the C1' file in which all possible subsequences extracted from the given DNA sequence database are stored and the hash map in which candidate primers that have passed Single Primer Filtering are stored. , If the primers of each set are identical except for the 5' end, the primers stored in the hash map can be updated to indicate 'not valid'. For example, the CPU 102 is based on two C1' files including all possible candidate primers extracted from a given DNA database and suffixH generated based on primers that have passed Single Primer Filtering. When pair-joining is performed between primers having the same suffix, and the C1' primer and the primer in suffixH have different sidsets except for the 5' end, valid at primerH for the corresponding primer ' It can be set to '0', which means 'not valid'. Although the C1' primer and the fry in suffixH have the same very high similarity except for the 5' end, having different sidsets means that the corresponding primer can also amplify off-target sequences, so this should be removed.

제4 단계는, 싱글 프라이머 필터링(Single Primer Filtering)과 5' Cross-Hybridization Filtering을 모두 통과한 프라이머가 저장된 해쉬맵으로부터 프라이머를 여러 개의 sid로 나누어 또 다른 해쉬맵을 생성하는 단계, 또 다른 해쉬맵으로부터 싱글 프라이머 필터링(Single Primer Filtering) 및 5' Cross-Hybridization Filtering을 모두 통과한 프라이머에 대한 정보를 가지는 데이터 구조 arraysC3와 주어진 DNA 서열 데이터베이스에 추출된 모든 가능한 부분서열에 대한 정보를 가지는 데이터 구조 arraysC1을 생성하는 단계, 및 생성한 데이터 구조를 GPU(103)에 복사하여 arraysC1과 arraysC3의 페어조인을 수행하면서 각각의 세트 내의 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지가 동일한 경우, arraysC3의 프라이머에 대해 '타당하지 않음'을 나타내도록 업데이트 하는 단계를 포함할 수 있다. The fourth step is to generate another hash map by dividing the primers into several sids from the hash map in which the primers that have passed both Single Primer Filtering and 5' Cross-Hybridization Filtering are stored, and another hash map. A data structure arraysC3 having information on primers that have passed both Single Primer Filtering and 5' Cross-Hybridization Filtering from and data structure arraysC1 having information on all possible subsequences extracted from a given DNA sequence database generating step, and copying the generated data structure to the GPU 103 to perform pair-joining of arraysC1 and arraysC3, and when the primers in each set are the same except for the given mismatch number (#mismatch), the primers of arraysC3 It may include updating to indicate 'not valid' for

한편, 제4 단계는, GPU(103)를 활용하여 연산을 수행하는 첫 번째 단계로, GPU(103)를 활용해 효율적으로 연산을 처리할 수 있도록 데이터 구조를 준비하고, 생성된 배열을 바탕으로 GPU(103)를 활용하여 C1'의 프라이머와 싱글 프라이머 필터링(Single Primer Filtering)과 5' Cross-Hybridization Filtering을 모두 통과한 프라이머 사이에 주어진 불일치수(#mismatch)를 제외한 나머지가 동일한 동시에 다른 sidset을 가지고 있는 경우의 프라이머에 대한 결과를 가지고 있는 output 배열에 '타당하지 않음'을 표시하며, GPU(103)로부터 결과를 저장하고 있는 output 배열을 호스트로 복사하여 General Cross-Hybridization Filtering 에서 제거된 프라이머에 대해 primerH에서 valid를 '타당하지 않음'을 뜻하는 '0'으로 설정하고, 이후 제5 단계에서 활용하기 위해 싱글 프라이머 필터링(Single Primer Filtering), 5' Cross-Hybridization Filtering, General Cross-Hybridization Filtering을 모두 통과한 프라이머를 저장 및 정렬하여

Figure 112020120544080-pat00006
형태의 C4 파일을 생성할 수 있다.On the other hand, the fourth step is the first step of performing an operation using the GPU 103, preparing a data structure so that the operation can be efficiently processed using the GPU 103, and based on the created array. Utilizing the GPU 103, the rest is the same except for the number of mismatches (#mismatch) given between the C1' primer and the primers that have passed both Single Primer Filtering and 5' Cross-Hybridization Filtering. At the same time, another sidset Display 'not valid' in the output array having the result for the primer if you have it, and copy the output array storing the result from the GPU (103) to the host to apply to the primer removed from General Cross-Hybridization Filtering. For primerH, set valid to '0', which means 'not valid', and then use Single Primer Filtering, 5' Cross-Hybridization Filtering, and General Cross-Hybridization Filtering for use in the fifth step. Save and align primers that have all passed
Figure 112020120544080-pat00006
A C4 file of the form can be created.

제5 단계는, 동일한 sid를 가지는 후보 프라이머를 그룹화하여 프라이머 개수가 작은 순으로 정렬하는 단계, 정렬한 파일을 입력으로 받아 후보 프라이머를 DNA 서열 데이터베이스에서 추출할 때 수행했던 표시의 유무에 따라 정방향 프라이머와 역방향 프라이머 두 세트로 분리하여 각각에 대해 GPU(103) 연산에 사용될 데이터 구조를 생성하고 페널티 점수를 저장할 수 있는 데이터 구조를 생성하는 단계, 생성된 데이터 구조를 GPU(103)에 복사하여 GPU(103) 내에서 같은 sid 내의 정방향 프라이머와 역방향 프라이머 사이의 페어조인 연산을 수행하며 복수개의 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용해 조건을 만족하는 프라이머에 대해서만 페널티 점수를 계산하여 저장하는 단계, 및 페널티 점수가 저장된 데이터 구조를 메인 메모리(104)로 복사해 결과물을 출력하고 동일한 sidset을 기준으로 그룹화 하여, 각 sidset에서 페널티 점수를 이용해 프라이머 쌍의 순서를 부여해 정렬하는 단계를 포함할 수 있다. In the fifth step, candidate primers having the same sid are grouped and sorted in descending order of the number of primers. Forward primers are selected according to the presence or absence of marking performed when extracting candidate primers from the DNA sequence database by receiving the sorted file as an input. and two sets of reverse primers to create a data structure to be used for GPU 103 operation for each and create a data structure capable of storing a penalty score, copying the generated data structure to the GPU 103 to the GPU ( 103) performs a pair-join operation between forward and reverse primers within the same sid, applies a plurality of pair primer filtering conditions, and calculates and stores penalty scores only for primers that satisfy the conditions; and copying the data structure in which the penalty score is stored to the main memory 104, outputting the result, grouping based on the same sidset, and assigning an order to primer pairs using the penalty score in each sidset to align.

여기서, 제5 단계는, GPU(103)를 활용해 연산을 수행하는 두 번째 단계로, 제4 단계에서 생성한 C4를 읽으면서 GPU(103) 연산에 필요한 데이터 구조를 준비하고, GPU(103) 연산을 통해 주어진 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 만족하는 쌍 프라이머에 대해 쌍 프라이머 페널티 점수를 계산하며, 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 만족하는 쌍 프라이머를 출력하여 동일한 sidset을 가지는 쌍 프라이머들에 대해 페널티 점수를 바탕으로 정렬하여 최종 결과를 출력할 수 있다. 여기서, 복수개의 쌍 프라이머 필터링(Pair Primer Filtering) 조건은, 길이 차이, 온도 차이, 생성물의 길이, Pair-Complementary 및 3' End Pair-Complementary를 포함할 수 있다. 이를 아래에서 도 3을 참조하여 보다 상세히 설명한다.Here, the fifth step is the second step of performing an operation using the GPU 103. While reading the C4 generated in the fourth step, a data structure required for the GPU 103 operation is prepared, and the GPU 103 Pair primer penalty scores are calculated for pair primers that satisfy the pair primer filtering conditions given through operation, and pair primers that satisfy the pair primer filtering conditions are output to obtain pairs with the same sidset. The final result can be output by sorting the primers based on the penalty score. Here, the plurality of pair primer filtering conditions may include length difference, temperature difference, product length, Pair-Complementary, and 3' End Pair-Complementary. This will be described in more detail with reference to FIG. 3 below.

도 3은 일 실시예들에 따른 GPU를 활용하여 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 프라이머들을 디자인하는 방법을 나타내는 흐름도이다.3 is a flowchart illustrating a method of designing effective primers that simultaneously satisfy primer restriction conditions and specificity conditions in a DNA sequence database using a GPU according to an embodiment.

도 3에 도시된 바와 같이, 주어진 DNA 서열 데이터베이스와 필터링 조건을 입력 받아, 모든 가능한 최소길이(minLen)와 최대길이(maxLen) 사이를 갖는 부분서열들의 후보 프라이머를 추출할 수 있다(S301, S302).As shown in FIG. 3, given a DNA sequence database and filtering conditions, candidate primers of subsequences having all possible minimum lengths (minLen) and maximum lengths (maxLen) can be extracted (S301, S302). .

이어, 상기 S302 단계에서 추출된 후보 프라이머에 대해, C1 파일을 입력으로 받아 S301 단계에서 입력 받은 싱글 프라이머 필터링(Single Primer Filtering) 조건을 만족하는 프라이머에 대해 primerH와 suffixH를 생성하고 C2 파일을 출력할 수 있다(S303).Subsequently, for the candidate primers extracted in step S302, the C1 file is received as an input, primerH and suffixH are generated for primers satisfying the single primer filtering condition input in step S301, and the C2 file is output. It can (S303).

그리고, 상기 S302 단계에서 얻어진 모든 가능한 부분서열을 포함하고 있는 C1' 파일을 입력으로 받아, 상기 S303 단계에서 생성한 suffixH 내의 프라이머와 페어조인(Pair Join)을 하면서, 만약 C1' 파일의 프라이머와 suffixH 내의 프라이머가 5' 끝부분을 제외하고 나머지 부분이 똑같다면 suffixH 내의 프라이머에 대해 primerH를 참조해 valid 값(유효 값)을 '타당하지 않음'으로 업데이트 할 수 있다(S304).In addition, the C1' file containing all possible subsequences obtained in step S302 is received as an input, and while performing Pair Join with the primers in suffixH generated in step S303, if the primers in the C1' file and suffixH If the rest of the primers are the same except for the 5' end, the valid value (valid value) can be updated to 'not valid' by referring to primerH for the primers in suffixH (S304).

또한, 상기 S304 단계에서 업데이트된 primerH를 바탕으로 seedH 해쉬맵을 생성하고, GPU 내에서의 효율적인 연산을 수행하기 위한 데이터 구조인 arraysC3를 seedH를 바탕으로 생성할 수 있다. 또한, 상기 S302 단계에서 얻어진 모든 가능한 부분서열을 포함하고 있는 C1' 파일을 입력으로 받아 arraysC1을 생성할 수 있다. arraysC1과 arraysC3는 GPU로 복사되어 GPU 내에서 페어조인을 하여 두 배열(arraysC1 및 arraysC3) 내의 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지가 같다면 그 결과를 output 배열에 표시해 두고, GPU 내에서의 모든 연산이 끝나면 output 배열을 다시 호스트로 복사하여 arraysC3 내의 프라이머에 대해 primerH를 참조해 valid 값을 '타당하지 않음'으로 업데이트 할 수 있다(S306, S307, S308).In addition, seedH hash map may be generated based on primerH updated in step S304, and arraysC3, which is a data structure for performing efficient operation in the GPU, may be generated based on seedH. In addition, arraysC1 may be generated by receiving the C1' file including all possible subsequences obtained in step S302 as an input. arraysC1 and arraysC3 are copied to the GPU and paired in the GPU. If the primers in the two arrays (arraysC1 and arraysC3) are the same except for the number of mismatches (#mismatch) given, the result is displayed in the output array, and in the GPU After all the calculations are finished, the output array can be copied back to the host, and the valid value can be updated to 'not valid' by referring to primerH for the primers in arraysC3 (S306, S307, S308).

그리고, C2 파일을 읽으면서 valid 값이 타당한 프라이머들만 출력하여 sid를 기준으로 그룹핑했을 때 포워드 프라이머 개수가 작은 순으로 순차 정렬하여 출력 파일인 C4 파일을 생성할 수 있다(S309).In addition, when the C2 file is read, only primers having a valid valid value are output, and when grouped based on sid, the C4 file, which is an output file, can be generated by sequentially sorting in descending order of the number of forward primers (S309).

상기 S309 단계의 결과에서 생성한 C4 파일에서 정방향 프라이머 세트와 역방향 프라이머 세트, 두 세트로 나누어 각각 arraysFP와 arraysRP 배열을 생성하고, 모든 정방향 프라이머와 역방향 프라이머의 쌍 프라이머의 조합에 대한 페널티 점수를 저장할 수 있는 scoreoffset, score 배열을 생성할 수 있다. 생성한 배열들은 GPU로 복사하여, GPU 내에서 arraysFP와 arraysRP에 대해 동일한 sid를 가지는 프라이머끼리 셀프 조인 계산을 하여 프라이머 쌍들을 위한 필터링 조건을 적용하여 조건을 만족하는 프라이머에 대해서만 페널티 점수를 계산하고 그 결과를 score 배열에 저장할 수 있다. 이후, score 배열은 다시 메인 메모리로 복사되어 primerH를 참조해 정방향 프라이머와 역방향 프라이머의 공통 sidset을 찾고 페널티 점수와 함께 출력할 수 있다(S310). In the C4 file generated as a result of step S309, a forward primer set and a reverse primer set are divided into two sets, arraysFP and arraysRP arrays are generated, respectively, and penalty scores for combinations of all paired primers of forward and reverse primers can be stored. You can create an array of scoreoffset and score. The generated arrays are copied to the GPU, and self-join calculations are performed between primers having the same sid for arraysFP and arraysRP in the GPU, and filtering conditions for primer pairs are applied to calculate penalty scores only for primers that satisfy the conditions. You can store the results in a score array. Thereafter, the score array is copied back to the main memory, and a common sidset of the forward and reverse primers can be found by referring to primerH and output together with a penalty score (S310).

그리고, 상기 S310 단계를 통과하여 출력한 프라이머 쌍들에 대해 공통 sidset을 가지는 그룹 내에서 페널티에 따라 순차 정렬하여 순차 정렬된 프라이머 쌍의 결과를 얻게 되는 것이다(S311, S312).Then, the primer pairs output through step S310 are sequentially aligned according to a penalty within the group having a common sidset, and the result of sequentially aligned primer pairs is obtained (S311, S312).

도 4는 일 실시예에 따른 후보 프라이머 추출 방법을 나타내는 흐름도이다. 보다 구체적으로, 도 4는 도 3에 도시된 S302 단계의 후보 프라이머 추출 동작에 대한 상세 흐름도이다. 4 is a flowchart illustrating a method of extracting candidate primers according to an embodiment. More specifically, FIG. 4 is a detailed flowchart of the candidate primer extraction operation of step S302 shown in FIG. 3 .

도 4에 도시된 바와 같이, S401 단계에서 DNA 데이터베이스를 서열 번호인 sid와 서열 데이터 S의 쌍인 sid+S의 형태로 입력 받아, 모든 가능한 최소길이(minLen)와 최대길이(maxLen) 사이의 길이를 갖는 후보 프라이머에 대한 부분서열을 윈도우 슬라이딩 방식으로 추출할 수 있다(S402). As shown in FIG. 4, in step S401, the DNA database is input in the form of sid + S, which is a pair of sequence number sid and sequence data S, and the length between all possible minimum lengths (minLen) and maximum lengths (maxLen) A partial sequence for a candidate primer having the same may be extracted using a window sliding method (S402).

즉, 길이 |S|인 서열에서 0부터 |S|-minLen를 시작점으로 길이 minLen에서 maxLen까지 증가하여 순차적으로 부분서열을 추출할 수 있다. 이 때, pos는 시작점이 되고 P는 시작점 pos에서 minLen 과 maxLen 사이의 길이에 해당하는 부분서열로 후보 프라이머가 된다. 길이 minLen과 maxLen 값은 싱글 프라이머 필터링(Single Primer Filtering) 조건 중 하나로 사용자로부터 입력 받는다.That is, subsequences may be sequentially extracted from a sequence having a |S| length from 0 to |S|-minLen as a starting point and increasing from a length of minLen to maxLen. At this time, pos is the starting point and P is a partial sequence corresponding to the length between minLen and maxLen at the starting point pos and becomes a candidate primer. The length minLen and maxLen values are input from the user as one of the Single Primer Filtering conditions.

이어, S403 단계에서 역방향 상보적 프라이머 또한 '*' 표시를 붙여 추출할 수 있다.Then, in step S403, reverse complementary primers can also be extracted by attaching a '*' mark.

그리고, S404 단계에서 동일한 각 프라이머 별 sid의 집합인 sidset을 추출할 수 있다.In step S404, sidset, which is a set of sids for each primer, may be extracted.

S405 단계에서는 두 파일 C1 파일과 C1' 파일을 출력할 수 있다. 이 때, C1 파일은

Figure 112020120544080-pat00007
의 형식으로 출력되고, C1' 파일은
Figure 112020120544080-pat00008
의 형식으로 출력될 수 있다. 여기서 P는 프라이머 후보, sid는 P가 나온 하나의 특정 서열의 번호, pos은 sid 서열 내에 P의 위치를 뜻하며, sidset은 P가 나온 sid의 집합을 뜻한다. In step S405, the two files C1 and C1' can be output. At this time, the C1 file is
Figure 112020120544080-pat00007
, and the C1' file is
Figure 112020120544080-pat00008
can be output in the form of Here, P is a primer candidate, sid is the number of one specific sequence from which P is derived, pos is the position of P within the sid sequence, and sidset is the set of sids from which P is derived.

도 5는 일 실시예에 따른 C1 파일 및 C1' 파일의 예시를 나타내는 도면이다. 보다 구체적으로, 도 5의 (a)는 도 3의 S302 단계의 출력물 C1 파일 및 C1' 파일의 예시를 나타내고, (b)는 도 3의 S303, S304, S306, S310 단계에 사용되는 해쉬맵들에 대한 예시를 나타낸다.5 is a diagram illustrating examples of a C1 file and a C1' file according to an embodiment. More specifically, (a) of FIG. 5 shows an example of the output C1 file and C1' file of step S302 of FIG. 3, and (b) shows hash maps used in steps S303, S304, S306, and S310 of FIG. shows an example for

도 6은 일 실시예에 따른 싱글 프라이머 필터링(Single Primer Filtering) 조건을 만족하는 프라이머에 대한 해쉬맵 생성 방법을 나타내는 흐름도이다. 보다 구체적으로, 도 6은 도 3에 도시된 S303 단계의 싱글 프라이머 필터링(Single Primer Filtering) 및 {primerH, suffix} 생성 동작에 대한 상세 흐름도로, 도 3의 S303 단계는 S301 단계에서 입력 받은 필터링 조건 중 7 개의 싱글 프라이머 필터링(Single Primer Filtering) 조건들을 적용하여 상기 S302 단계에서 추출된 후보 프라이머의 적합성을 확인할 수 있다.6 is a flowchart illustrating a method for generating a hash map for primers satisfying a single primer filtering condition according to an embodiment. More specifically, FIG. 6 is a detailed flowchart of single primer filtering and {primerH, suffix} generation operations in step S303 shown in FIG. 3, and step S303 in FIG. Among them, seven single primer filtering conditions may be applied to confirm the suitability of the candidate primers extracted in step S302.

도 6에 도시된 바와 같이, S601 단계에서 C1 파일을 입력 받아 순차적으로 읽으면서, S602 단계 내지 S608 단계에서처럼, 조건으로 온도(℃), GC content(%), Self-Complementarity, 3' End Self-Complementary, 연속된 염기, end stability(G value)를 순차적으로 확인할 수 있다(S602 ~ S608).As shown in FIG. 6, while receiving and sequentially reading the C1 file in step S601, as in steps S602 to S608, temperature (℃), GC content (%), Self-Complementarity, 3' End Self- Complementary, consecutive bases, and end stability (G value) can be sequentially checked (S602 ~ S608).

상기 조건들은 모두 사용자에 의해 값이 정의될 수 있다. 특히, 온도나 end stability 등을 계산하기 위해서는 상기 언급된 MRPrimer에서 적용되었던 공식을 동일하게 적용하였다.Values of all of the conditions may be defined by the user. In particular, the same formula applied in the above-mentioned MRPrimer was applied to calculate temperature or end stability.

모든 싱글 프라이머 필터링(Single Primer Filtering) 조건들을 만족하는 프라이머들을 바탕으로 primerH와 suffixH 해쉬맵을 생성할 수 있다. primerH는 프라이머인 P를 키로 가지고, sidset과 valid를 값으로 가진다. sidset은 해당 P가 나타나는 sid의 집합이고, valid는 그 프라이머가 타당한지 타당하지 않은지를 나타내는 값으로, 초기에는 모두 '타당함(true)'을 나타내는 '1'로 초기화된다. suffixH는, 이후 도 3에 도시된 S304 단계의 동작을 위해 생성하는 해쉬맵으로 키는 프라이머의 3' 끝부분의 특정 길이만큼의 부분서열을 뜻하는 suffix이다. 또한, 해당 suffix를 가지는 프라이머의 집합인 Pset을 값으로써 가진다(S609, S610). 한편, S609 및 S610 단계에서 생성되는 primerH와 suffix 해쉬맵의 예시는 도 5의(b)에 도시되어 있다.PrimerH and suffixH hash maps can be generated based on primers that satisfy all Single Primer Filtering conditions. primerH has primer P as a key, and has sidset and valid as values. sidset is a set of sids in which the corresponding P appears, valid is a value indicating whether the primer is valid or not, and is initially initialized to '1' indicating 'true'. suffixH is a hash map generated for the operation of step S304 shown in FIG. 3, and the key is suffix denoting a partial sequence of a specific length of the 3' end of the primer. In addition, it has Pset, which is a set of primers having the corresponding suffix, as a value (S609, S610). Meanwhile, an example of primerH and suffix hash map generated in steps S609 and S610 is shown in (b) of FIG.

또한, 모든 싱글 프라이머 필터링(Single Primer Filtering) 조건들을 만족하는 프라이머들은 입력 파일과 동일하게

Figure 112020120544080-pat00009
형식으로 출력하여 출력 파일인 C2 파일을 생성할 수 있다(S611). In addition, primers that satisfy all Single Primer Filtering conditions are identical to the input file.
Figure 112020120544080-pat00009
A C2 file, which is an output file, can be generated by outputting in the format (S611).

도 7은 일 실시예에 따른 5' Cross-Hybridization Filtering 방법을 나타내는 흐름도이다. 보다 구체적으로, 도 7은 도 3에 도시된 S304 단계의 5' Cross-Hybridization Filtering 동작에 대한 상세 흐름도를 나타낸다.7 is a flowchart illustrating a 5' Cross-Hybridization Filtering method according to an embodiment. More specifically, FIG. 7 shows a detailed flowchart of the 5' Cross-Hybridization Filtering operation of step S304 shown in FIG. 3 .

도 7을 참조하면, 도 3의 S304 단계는 주어진 DNA 서열 데이터베이스에서 추출된 모든 가능한 부분서열을 가지고 있는 C1' 파일을 입력으로 받아 이를 순차적으로 읽으면서 각 프라이머 P1으로부터 suffix를 분리할 수 있다(S701).Referring to FIG. 7, in step S304 of FIG. 3, a C1' file containing all possible subsequences extracted from a given DNA sequence database is received as an input and sequentially read to separate suffixes from each primer P1 (S701 ).

그리고, 도 3의 S303 단계에서 생성된 suffixH에 해당 suffix가 존재하는 경우에는 suffixH에서 해당 suffix를 가지는 Pset을 룩업함으로써 프라이머 P1과 Pset 내의 프라이머 P2의 페어조인을 수행할 수 있다(S702, S703).And, if the corresponding suffix exists in the suffixH generated in step S303 of FIG. 3, pair-joining of the primer P1 and the primer P2 in the Pset can be performed by looking up the Pset having the corresponding suffix in the suffixH (S702, S703).

특정 suffix를 가지는 Pset의 프라이머 P2의 valid 값을 primerH에서 확인하여 그 값이 '타당함(true)'인 경우에는 P1의 sidset과 P2의 sidset을 비교할 수 있다. P1의 sidset의 경우 C1'파일을 통해 입력 받았고, P2의 sidset의 경우 primerH를 참조함으로써 얻을 수 있다. P1의 sidset 중에 P2의 sidset에 포함되지 않은 sid가 존재하는 경우 P2가 비표적 타겟인 해당 sid의 서열 또한 증폭시킬 수 있는 가능성이 있기 때문에 P2는 제거되어야 한다. 따라서 그러한 프라이머 P2의 경우 primerH 내의 valid 값은 '타당하지 않음(false)'로 업데이트 할 수 있다(S704, S705, S706). The valid value of primer P2 of the Pset having a specific suffix is checked in primerH, and if the value is 'true', the sidset of P1 and the sidset of P2 can be compared. In the case of the sidset of P1, it was received through the C1' file, and in the case of the sidset of P2, it can be obtained by referring to primerH. If there is a sid in the sidset of P1 that is not included in the sidset of P2, P2 should be removed because there is a possibility that P2 can also amplify the sequence of the corresponding sid, which is an off-target. Therefore, in the case of such primer P2, the valid value in primerH can be updated to 'false' (S704, S705, S706).

상기와 같은 5' Cross-Hybridization Filtering 동작의 적용 예시는 도 5의 (a) 및 (b)를 참조하여 설명할 수 있다.An example of applying the 5' Cross-Hybridization Filtering operation as described above can be described with reference to (a) and (b) of FIG. 5 .

도 5의 (a)의 C1' 파일의 세 번째 행에 나타나는 GCT가 도 3에 도시된 S303 단계에서 싱글 프라이머 필터링(Single Primer Filtering) 조건을 만족하지 못해 도 5의 (b) primerH와 suffixH 내에 해당 프라이머에 대한 정보가 없다고 가정한다. C1' 파일의 'GCT+3'의 경우 suffix CT를 가지기 때문에 suffixH에서 해당 suffix를 가지는 Pset을 룩업하여 {*TCT} 집합을 찾는다. primerH에서 이 *TCT를 찾게 되면 해당 프라이머가 {4-5}를 sidset으로 가짐을 알 수 있고, GCT의 sidset인 {3}은 해당 {4-5}에 포함되지 않는다. 이 경우 프라이머 *TCT가 높은 유사도로 인하여 비표적 서열인 sid 3 또한 증폭시킬 수 있기 때문에 프라이머 *TCT는 '타당하지 않음(false)'로 업데이트된다.The GCT appearing in the third row of the C1' file in (a) of FIG. 5 does not satisfy the single primer filtering condition in step S303 shown in FIG. 3, and corresponds to primerH and suffixH in (b) of FIG. 5 It is assumed that there is no information about the primers. In the case of 'GCT+3' in the 'C1' file, since it has a suffix CT, the {*TCT} set is found by looking up the Pset having the suffix in suffixH. If this *TCT is found in primerH, it can be seen that the primer has {4-5} as the sidset, and the sidset of GCT, {3}, is not included in the corresponding {4-5}. In this case, since primer *TCT can also amplify sid 3, which is an off-target sequence, due to high similarity, primer *TCT is updated to 'false'.

구현적 측면에서 C1' 파일은 CPU 쓰레드의 개수와 동일한 개수의 파일로 나뉘어 저장되어 있고, 여러 CPU 쓰레드들은 각각의 파일을 읽으면서 primerH를 업데이트 시킨다. 룩업의 경우 원자 단위 연산(atomic operation)이기 때문에 쓰레드 간의 경합(race condition) 없이 빠른 연산 수행이 가능하다. In terms of implementation, the C1' file is divided into the same number of files as the number of CPU threads, and several CPU threads update primerH while reading each file. In the case of lookup, because it is an atomic operation, it is possible to perform a fast operation without race conditions between threads.

도 8은 일 실시예에 따른 {seedH, arraysC1, arraysC3} 생성 및 General Cross-Hybridization Filtering 방법을 나타내는 흐름도이다. 보다 구체적으로, 도 8은 도 3에 도시된 S306 단계의 {seedH, arraysC1, arraysC3} 생성 및 General Cross-Hybridization Filtering 동작의 상세 흐름도이다.8 is a flowchart illustrating a method of generating {seedH, arraysC1, arraysC3} and general cross-hybridization filtering according to an embodiment. More specifically, FIG. 8 is a detailed flowchart of {seedH, arraysC1, arraysC3} generation and general cross-hybridization filtering operations in step S306 shown in FIG. 3 .

도 3의 S306 단계는 GPU를 활용하여 효율적으로 연산을 처리할 수 있도록 데이터 구조 (seedH, arraysC1, arraysC3)를 준비하고 생성된 데이터 구조들을 바탕으로 C1' 파일의 프라이머와 싱글 프라이머 필터링(Single Primer Filtering)과 5' Cross-Hybridization Filtering을 통과한 프라이머 사이에 주어진 불일치수(#mismatch)를 제외한 나머지가 동일한 동시에 다른 sidset을 가지고 있는 경우 해당 프라이머에 대해 primerH에서 valid를 '타당하지 않음'을 뜻하는 '0'으로 설정할 수 있다.In step S306 of FIG. 3, data structures (seedH, arraysC1, arraysC3) are prepared to efficiently process operations using the GPU, and primers and single primer filtering of the C1' file are performed based on the generated data structures. ) and the primers that passed 5' Cross-Hybridization Filtering, except for the given number of mismatches (#mismatch), if they have different sidsets at the same time, valid in primerH for that primer is 'not valid'. Can be set to 0'.

이 과정을 효과적으로 수행하기 위해 S306 단계는 프라이머를 여러 개의 시드(Seed)로 나누어 연산을 수행하는데, 하나의 프라이머에서 생성될 수 있는 시드의 길이는 k 개의 불일치를 갖는 m 길이 서열에서 적어도 정확히 일치하는 m/(k+1) 염기를 포함할 수 있도록 설정할 수 있다.In order to effectively carry out this process, step S306 divides the primers into several seeds and performs the operation. The length of the seed that can be generated from one primer is at least exactly matched in m-length sequences with k mismatches. It can be set to include m/(k+1) bases.

도 8을 참조하면, 상기 싱글 프라이머 필터링(Single Primer Filtering)과 5' Cross-Hybridizatiopn Filtering을 모두 통과한 후보 프라이머에 대해서만 valid 값이 '타당함(true)'로 표시되어 있는 primerH를 순차적으로 룩업하며, 해당 프라이머가 타당한 경우에 대해 프라이머로부터 시드를 추출하여 seedH를 업데이트 할 수 있다. 이 때, seedH의 키는

Figure 112020120544080-pat00010
이고 값은 Pset이다. 키에서의 seed는 프라이머의 시드를 뜻하고 index는 시드가 시작하는 위치, |P|는 프라이머의 길이를 나타내며, seedH의 값인 Pset은 해당 키를 가지고 있는 프라이머의 집합을 뜻한다. 하나의 프라이머에서 여러 개의 시드가 추출되기 때문에 하나의 프라이머로부터 여러 개의 키가 생성된다(S801, S802, S803).Referring to FIG. 8, only for candidate primers that have passed both the Single Primer Filtering and the 5' Cross-Hybridizatiopn Filtering, primerH whose valid value is marked as 'true' is sequentially looked up, , seedH can be updated by extracting a seed from the primer for the case where the corresponding primer is valid. At this time, the key of seedH is
Figure 112020120544080-pat00010
and the value is Pset. The seed in the key means the seed of the primer, index is the starting position of the seed, |P| indicates the length of the primer, and Pset, the value of seedH, means the set of primers with the corresponding key. Since several seeds are extracted from one primer, several keys are generated from one primer (S801, S802, S803).

seedH의 생성이 완료되면 seedH로부터 arraysC3와 output 배열을 생성하여 GPU에 복사할 수 있다. arraysC3는 P3offset, P3, sidset3offset, sidset3 네 가지 배열로 구성되어 있다(S804). When the creation of seedH is complete, arraysC3 and output arrays can be created from seedH and copied to the GPU. arraysC3 consists of four arrays: P3offset, P3, sidset3offset, and sidset3 (S804).

S804 단계의 동작의 적용 예시를 도 5의 (b) 및 도 9의 (a)의 예시를 통해 확인할 수 있다.An application example of the operation of step S804 can be confirmed through examples of FIG. 5(b) and FIG. 9(a).

도 9는 일 실시예에 따른 {seedH, arraysC1, arraysC3} 생성 및 General Cross-Hybridization Filtering의 예시를 나타내는 도면이다.9 is a diagram illustrating an example of generating {seedH, arraysC1, arraysC3} and general cross-hybridization filtering according to an embodiment.

arraysC3의 생성을 위해서, 먼저 seedH의 키를 Pset의 크기(각 키에 대한 프라이머의 개수)의 오름차순으로 정렬할 수 있다. 키의 순서는 GPU 연산의 작업부하 밸런싱(workload balancing)을 처리하기 위해 사용되며 이 순서를 작업부하 순서(workload order)라고 부른다. 그리고 나서 P3와 sidset3 배열을 작업부하 순서에 따라 생성할 수 있다.To create arraysC3, first, the keys of seedH can be sorted in ascending order of the size of Pset (the number of primers for each key). The order of keys is used to handle workload balancing of GPU operations, and this order is called workload order. Then you can create P3 and sidset3 arrays in order of workload.

도 5의 (b)의 seedH의 경우, 'A+0+3'와 'G+2+3'의 키를 가지는 프라이머의 개수는 2이고, 'T+1+3'을 가지는 프라이머 개수는 1이다. 따라서 Pset의 크기가 가장 작은 'T+1+3'의 키에 대한 Pset {ATG}로 프라이머 정보를 가지고 있는 배열 P3를 우선적으로 생성하고, 그 다음으로 'A+0+3'의 Pset {AAC, ATG}으로 P3를 업데이트 할 수 있다. 이와 마찬가지로 sidset 정보를 가지고 있는 배열 sidset3은 도 5의 (b)의 primerH를 참조하여 'T+1+3'의 ATG의 sidset {1-2}로 시작되고 그 다음 'A+0+3'의 AAC의 sidset {2-3-4}, ATG의 sidset {1,2}의 순서로 생성된다. 도 9의 (a)의 P3offset과 sidset1offset은 단순히 P3와 sidset3의 포인터 배열로써 동작할 수 있다. In the case of seedH in (b) of FIG. 5, the number of primers having keys of 'A+0+3' and 'G+2+3' is 2, and the number of primers having keys of 'T+1+3' is 1 am. Therefore, array P3 having primer information is first created as Pset {ATG} for the key of 'T+1+3' with the smallest Pset size, and then Pset {AAC of 'A+0+3' , ATG} can update P3. Similarly, array sidset3 having sidset information starts with sidset {1-2} of ATG of 'T+1+3' with reference to primerH in (b) of FIG. 5, followed by 'A+0+3' It is created in the order of sidset {2-3-4} of AAC and sidset {1,2} of ATG. P3offset and sidset1offset in (a) of FIG. 9 may simply operate as a pointer array of P3 and sidset3.

도 9의 (a)의 output 배열은 General Cross-Hybridization Filtering의 결과를 저장하기 위한 배열로, 각 프라이머에 대한 필터링 결과를 나타내는 것이기 때문에 P3와 동일한 크기를 가진다. 이 output 배열은 '타당함(true)'을 뜻하는 '1'로 초기화되며, General Cross-Hybridization Filtering을 수행하면서 업데이트된다. The output array in (a) of FIG. 9 is an array for storing the results of General Cross-Hybridization Filtering, and has the same size as P3 because it represents the filtering results for each primer. This output array is initialized to '1', which means 'true', and is updated while performing General Cross-Hybridization Filtering.

이 때, arraysC3와 output 배열은 상기 싱글 프라이머 필터링(Single Primer Filtering)과 5' Cross-Hybridizatiopn Filtering을 모두 통과한 후보 프라이머에 대해 생성된 것이기 때문에 일반적으로 GPU에 한번에 복사 가능한 크기이다. 따라서 이들을 GPU에 한번에 복사하며, 이러한 복사를 청크 복사(Chunk-Copy)라고 부른다. At this time, arraysC3 and the output array are generated for candidate primers that have passed both the Single Primer Filtering and the 5' Cross-Hybridization Filtering, so they are generally of a size that can be copied to the GPU at once. Therefore, they are copied to the GPU at once, and this copying is called Chunk-Copy.

그 다음으로, DNA 서열 데이터베이스에서 추출된 모든 가능한 부분서열을 가지고 있는 C1' 파일을 입력으로 받아 이를 순차적으로 읽으면서 각 프라이머 P1으로부터 시드를 추출해 키(

Figure 112020120544080-pat00011
)를 생성할 수 있다. seedH 내에 해당 키가 존재하는 경우에 대해서만 arraysC1을 업데이트 할 수 있다(S805, S806, S807, S808).Next, the C1' file containing all possible subsequences extracted from the DNA sequence database is received as an input and the seed is extracted from each primer P1 while sequentially reading it as a key (
Figure 112020120544080-pat00011
) can be created. arraysC1 can be updated only when the corresponding key exists in seedH (S805, S806, S807, S808).

S808 단계에서 업데이트되는 arraysC1의 경우 P1offset, P1, sidset1offset, sidset1 네 가지 배열로 구성되어 있으며, 도 9의 (b)에 예시를 확인할 수 있다. arraysC3를 생성할 때와 동일한 작업부하 순서를 바탕으로 생성되며, P1은 프라이머 대한 정보를, sidset1은 각 프라이머에 대한 sidset 정보를 가지고 있는 배열이며, P1offset과 sidset1offset은 각각 P1과 sidset1에 대한 포인터 배열로 사용된다. In the case of arraysC1 updated in step S808, it is composed of four arrays: P1offset, P1, sidset1offset, and sidset1, and an example can be seen in (b) of FIG. It is created based on the same workload order as when arraysC3 was created. P1 is an array containing information about primers, sidset1 is an array containing sidset information about each primer, and P1offset and sidset1offset are arrays of pointers to P1 and sidset1, respectively. used

C1' 파일의 경우 DNA 서열 데이터베이스로의 모든 부분서열을 후보 프라이머로써 가지고 있기 때문에 이에 대한 arraysC1을 한번에 생성해서 GPU에 복사하기에는 GPU 메모리가 부족한 경우가 대다수이다. 따라서 C1' 파일의 경우 arraysC1이 한번에 GPU에 복사될 수 있는 크기만큼만 읽어서 arraysC1을 생성해 GPU에 복사해 연산을 수행하고, 이후 이전에 읽었던 부분의 다음 부분을 읽어 동일한 과정을 반복할 수 있다. 이 때, arraysC1의 생성 및 GPU로의 복사에 대한 오버헤드를 줄이기 위해서 이전 C1' 파일 조각에 대해 생성된 arraysC1이 GPU 내에서 연산을 수행하는 과정과 다음 C1' 파일의 조각에 대한 arraysC1을 생성하고 이를 GPU로 복사하는 과정이 동시에 이루어진다. 이러한 비동기적 연산 및 데이터 복사를 위하여 arraysC1의 복사는 GPU의 스트림을 활용하여 이루어지기 때문에 arraysC1에 대한 복사를 스트리밍 복사(Streaming-Copy)라고 부른다(S809, S810).In the case of the C1' file, since it has all subsequences to the DNA sequence database as candidate primers, in most cases the GPU memory is insufficient to create arraysC1 for them at once and copy them to the GPU. Therefore, in the case of the C1' file, arraysC1 is read only as much as the size that can be copied to the GPU at a time, arraysC1 is created, copied to the GPU, and the operation is performed. Then, the same process can be repeated by reading the next part of the previously read part. At this time, in order to reduce the overhead of creating arraysC1 and copying to the GPU, arraysC1 created for the previous C1' file piece performs an operation in the GPU and arraysC1 for the next C1' file piece is created and processed. The process of copying to the GPU is done simultaneously. For these asynchronous operations and data copying, copying of arraysC1 is called streaming-copy because the copying of arraysC1 is performed using a GPU stream (S809, S810).

GPU 내에서는 S804 단계에서 청크 복사된 arraysC3와 S810 단계에서 스트리밍 복사된 arraysC1을 이용해 동일한 키를 가지는 각각의 프라이머에 대해 페어조인 연산을 수행할 수 있다. 먼저 sidset1와 sidset3를 비교하여 P1의 sidset(sidset1)이 P3의 sidset(sidset3)에 포함되지 않고, 프라이머 P1와 P3 사이의 불일치 수가 설정한 #Mismatch 보다 작은 경우에는 두 프라이머(P1 및 P3)가 매우 유사도가 높음을 나타내기 때문에 P3가 비표적 서열을 증폭시킬 수 있고, 이에 따라 해당 프라이머의 output 값을 '타당하지 않음'을 나타내는 '0'으로 업데이트 시킨다(S811, S812, S813, S814). In the GPU, a pair-join operation can be performed on each primer having the same key using arraysC3 chunk-copied in step S804 and arraysC1 stream-copied in step S810. First, sidset1 and sidset3 are compared, and if the sidset (sidset1) of P1 is not included in the sidset (sidset3) of P3 and the number of mismatches between primers P1 and P3 is smaller than #Mismatch set, the two primers (P1 and P3) are very Since the similarity is high, P3 can amplify the off-target sequence, and accordingly, the output value of the corresponding primer is updated to '0' indicating 'not valid' (S811, S812, S813, S814).

S811, S812, S813, S814 단계의 동작의 적용 예시를 도 9의 (a) 및 (b)의 예시를 통해 확인할 수 있다.An application example of the operation of steps S811, S812, S813, and S814 can be confirmed through examples of (a) and (b) of FIG. 9 .

키 'T+1+3'을 가지는 P3는 {ATG}이고, P1은 {ATG, CTT, CTA}이다. P3인 ATG의 sidset {1,2}와 P1인 CTT의 sidset {4,5}를 비교하면, sidset1({4,5})이 sidset3({1,2})에 포함되지 않는다. 이 경우, 불일치수를 확인하게 되는데, ATG와 CTT의 불일치수는 2이고 #mismatch가 1이라고 가정하면 불일치수가 이보다 높기 때문에 output은 업데이트 되지 않는다. P3 with key 'T+1+3' is {ATG}, and P1 is {ATG, CTT, CTA}. Comparing sidset {1,2} of ATG, P3, and sidset {4,5} of CTT, P1, sidset1({4,5}) is not included in sidset3({1,2}). In this case, the number of mismatches is checked. Assuming that the number of mismatches of ATG and CTT is 2 and #mismatch is 1, the output is not updated because the number of mismatches is higher than this.

스트리밍 복사에 의해 현재 GPU가 가지고 있는 arraysC1과 arraysC3에 대한 GPU 내에서의 연산인 S811 단계 내지 S814 단계까지의 단계와 S805 단계에서 arraysC1을 초기화하고 아직 읽지 못한 부분의 C1' 파일을 읽으면서 arraysC1을 생성하여 복사하는 S810 단계까지의 연산이 동시에 수행되며, 모든 C1' 파일을 처리할 때까지 이와 같은 과정들이 반복된다(S805, S815, S816).By streaming copy, arraysC1 is initialized in steps S811 to S814 and steps S805, which are operations in the GPU for arraysC1 and arraysC3 currently possessed by the GPU, and arraysC1 is generated while reading the C1' file of the part that has not yet been read. Operations up to step S810 of copying are performed simultaneously, and these processes are repeated until all C1' files are processed (S805, S815, S816).

기본적으로 arraysC1과 arraysC3를 이용한 GPU 내의 연산은 키 단위로 독립적으로 이루어지는데, 한 키에 대한 프라이머 개수의 분포는 굉장히 다양하기 때문에 하나의 GPU 쓰레드가 하나의 키만 처리하는 경우, 특정 GPU 쓰레드는 굉장히 적은 양의 프라이머만 처리하고 특정 GPU 쓰레드는 굉장히 많은 프라이머를 처리하는 등, 작업부하에 대한 불균등을 가져올 수 있고 이것은 곧 GPU 연산 성능의 하락을 야기할 수 있다. 따라서 작업부하 밸런싱(Workload Balancing)을 위해서 특정 스레숄드(Threshold)를 설정하고 특정 키의 인덱스(Index)가 이 스레숄드보다 작으면 하나의 GPU 쓰레드가 하나의 키 내의 모든 프라이머를 처리하는 each-thread 모드를 적용하고, 특정 키의 인덱스가 스레숄드보다 큰 경우에는 하나의 쓰레드 블락 내의 모든 GPU 쓰레드가 하나의 키 내를 처리하도록 하는 block-threads 모드를 적용할 수 있다. P3는 상기에 설명된 바와 같이 작업부하 순서에 따라 정렬되어 있고, P1 또한 동일한 작업부하 순서를 따름에 따라 거의 정렬되어 있다고 볼 수 있기 때문에 특정 인덱스를 스레숄드로 설정하여 각각을 다르게 처리하는 것만으로도 작업부하 밸런싱이 가능하다. 이 스레숄드 값은 실험을 통하여 설정하였으며, 상기 도 3의 S305단계의 #ITERATION 값이 1일 때는 전체의 85%인 지점으로, #ITERATION 값이 2일 때는 20%인 지점으로 설정되어 있다.Basically, operations within the GPU using arraysC1 and arraysC3 are independently performed on a key-by-key basis. Since the distribution of the number of primers for a key varies greatly, when one GPU thread processes only one key, a specific GPU thread is very small. It can lead to an uneven workload, such as processing only the amount of primers and a specific GPU thread processing a lot of primers, which can lead to a decrease in GPU computational performance. Therefore, if a specific threshold is set for Workload Balancing and the index of a specific key is smaller than this threshold, one GPU thread processes all primers within one key. Each-thread mode If the index of a specific key is greater than the threshold, block-threads mode can be applied so that all GPU threads within one thread block process within one key. Since P3 is sorted according to the order of workload as described above, and P1 can be considered to be almost sorted according to the same order of workload, just setting a specific index as a threshold and processing each differently Workload balancing is possible. This threshold value was set through experimentation, and when the #ITERATION value in step S305 of FIG. 3 is 1, it is set at 85% of the total, and when the #ITERATION value is 2, it is set at 20%.

모든 C1' 파일에 대한 연산이 끝나면 최종 output 배열을 호스트로 복사하여 output에서 '타당하지 않음'을 뜻하는 '0'을 가지는 프라이머에 대해서는 primerH를 참조하여 그 valid 값을 똑같이 '타당하지 않음(false)'로 업데이트 할 수 있다(S816, S817, S818).After the operation of all C1' files is completed, copy the final output array to the host, and refer to primerH for primers with '0', which means 'not valid' in the output, and set the valid value to the same 'not valid' (false )' (S816, S817, S818).

이후, 도 3의 S303 단계에서 생성했던 C2 파일을 입력 파일로 받아 이를 읽으면서 primerH의 valid 값이 'true'인 프라이머에 대해서만 C2와 동일한

Figure 112020120544080-pat00012
의 포맷으로 출력할 수 있다(S819).Then, while receiving the C2 file generated in step S303 of FIG.
Figure 112020120544080-pat00012
It can be output in the format of (S819).

도 10은 일 실시예에 따른 {seedH, arraysC1, arraysC3} 생성 및 General Cross-Hybridization Filtering 방법에서의 데이터 흐름과 타임라인에 대한 예시를 나타내는 도면이다.10 is a diagram illustrating an example of a data flow and a timeline in a method of generating {seedH, arraysC1, arraysC3} and general cross-hybridization filtering according to an embodiment.

도 10의 (a) 및 (b)는 2 개의 GPU가 사용될 때, 전체 도 4의 상세 흐름도에 대한 데이터 흐름과 타임라인(timeline)을 나타낸 예시이다. 우선 primerH로부터 생성된 seedH를 바탕으로 메인 메모리 내에서 arraysC3와 output 배열을 생성하고, 이를 GPU 개수로 나누어 각 GPU에 청크 복사할 수 있다. 이 때, arraysC3 및 arraysC1를 이용한 연산은 키로 사용되는

Figure 112020120544080-pat00013
에 따라 독립적이기 때문에 한 키에 대한 모든 데이터가 하나의 GPU에 복사되어야 한다. 도 10의 (a)에서는 GPU가 두 개일 때의 예시이기 때문에 arraysC3와 output이 2 개로 나뉘어졌다. 청크 복사 끝나고 나면 N 개의 조각으로 나뉘어진 C1' 파일을 읽으면서 arraysC1을 생성할 수 있다. arraysC1 또한 각 GPU가 가지고 있는 키에 대해서만 각 GPU에게 복사된다. 이 때, 도 10의 (b)를 보면 arraysC1의 스트리밍 복사와 GPU 내의 커널 연산이 스트림을 이용하여 비동기적으로 수행됨을 알 수 있다. C1' 파일에 대한 모든 연산이 끝나면 output 배열은 다시 호스트에게 복사되어 primerH를 업데이트 하는데 사용된다.(a) and (b) of FIG. 10 are examples showing the data flow and timeline for the detailed flowchart of FIG. 4 when two GPUs are used. First, based on seedH generated from primerH, arraysC3 and output arrays are created in the main memory, and chunks can be copied to each GPU by dividing them by the number of GPUs. At this time, the operation using arraysC3 and arraysC1 is used as a key.
Figure 112020120544080-pat00013
is independent, so all data for one key must be copied to one GPU. In (a) of FIG. 10, since it is an example when there are two GPUs, arraysC3 and output are divided into two. After copying the chunks, arraysC1 can be created by reading the C1' file divided into N pieces. arraysC1 is also copied to each GPU only for the keys each GPU has. At this time, in (b) of FIG. 10 , it can be seen that the streaming copy of arraysC1 and the kernel operation in the GPU are performed asynchronously using the stream. After all operations on the C1' file are finished, the output array is copied back to the host and used to update primerH.

도 11은 일 실시예에 따른 Pair Filtering 및 Scoring 방법을 나타내는 흐름도이다. 보다 구체적으로, 도 11은 도 3에 도시된 S310 단계의 Pair Filtering 및 Scoring 동작의 상세 흐름도를 나타낸다.11 is a flowchart illustrating a pair filtering and scoring method according to an embodiment. More specifically, FIG. 11 shows a detailed flowchart of Pair Filtering and Scoring operations in step S310 shown in FIG. 3 .

S311 단계의 Pair Filtering 및 Scoring 단계는 도 3의 S306 단계에서 생성된 출력 파일을 S309 단계에서 sid를 기준으로 그룹핑 했을 때 포워드 프라이머 개수가 작은 순으로 순차 정렬하여 얻은 출력 파일인 C4 파일을 입력 파일로 받는다. 이 때, 순차 정렬은 이후 작업부하 밸런싱을 위한 것이다.In the Pair Filtering and Scoring step of step S311, when the output file generated in step S306 of FIG. 3 is grouped based on sid in step S309, the C4 file, which is an output file obtained by sequentially sorting in descending order of the number of forward primers, is used as an input file. receive At this time, sequential sorting is for later workload balancing.

C4 파일을 입력 받아 순차적으로 읽으면서 C4 파일의 프라이머를 정방향 프라이머(forward primer, f.p)와 역방향 프라이머(reverse primer, r.p)로 분리하여 GPU 연산에 필요한 배열인 arraysFP와 arraysRP를 생성할 수 있다. arraysFP는 정방향 프라이머에 대한 정보를 가지는 FP, 정방향 프라이머의 pos 정보를 가지는 Fpos과 FP, Fpos에 대한 포인터 배열로써의 역할을 하는 FPoffset, 이렇게 총 3 개의 배열들로 이루어져있다. arraysRP는 역방향 프라이머와 관련된 RPoffset, RP, Rpos 3 개의 배열들로 이루어져있으며, 각각의 의미는 arraysFP의 것과 동일하다(S1102, S1103). While receiving and reading the C4 file sequentially, the primers in the C4 file are separated into forward primers (f.p) and reverse primers (r.p) to generate arraysFP and arraysRP, which are arrays required for GPU operation. arraysFP consists of a total of three arrays: FP with forward primer information, Fpos and FP with forward primer pos information, and FPoffset serving as a pointer array to Fpos. arraysRP consists of three sequences, RPoffset, RP, and Rpos related to the reverse primer, and the meaning of each is the same as that of arraysFP (S1102, S1103).

S1103 단계의 동작의 적용 예시를 도 12의 (a), (b) 및 (c)를 통해 확인할 수 있다.Application examples of the operation of step S1103 can be confirmed through (a), (b) and (c) of FIG. 12 .

도 12는 일 실시예에 따른 프라이머 순차 정렬 방법의 예시를 나타내는 도면이다. 보다 구체적으로, 도 12의 (a)는 입력 파일로 사용되는 C4 파일의 예시이다. C4 파일에서 sid가 7인 정방향 프라이머는 {CGT}로 1 개이고, sid가 2인 정방향 프라이머는 {ATG, AAC}로 2 개이기 때문에 이와 같은 순서로 정렬되었다. 도 12의 (b) 및 (c)는 각각 arraysFP와 arryasRP에 대한 예시이다. 도 12의 (a)의 C4 파일을 순차적으로 읽으면서 각각 프라이머와 pos 정보를 읽어 프라이머가 정방향 프라이머인 경우에는 FP와 Fpos를 업데이트 하고 프라이머가 역방향 프라이머일 때는 RP와 Rpos를 업데이트 할 수 있다. 또한, sid가 바뀔 때마다 FPoffset과 RPoffset을 업데이트 할 수 있다.12 is a diagram showing an example of a primer sequence alignment method according to an embodiment. More specifically, (a) of FIG. 12 is an example of a C4 file used as an input file. In the C4 file, {CGT} is one forward primer with sid of 7, and {ATG, AAC} is two forward primers with sid of 2, so they are arranged in this order. 12 (b) and (c) are examples of arraysFP and arryasRP, respectively. While sequentially reading the C4 file of FIG. 12 (a), primer and pos information are read, respectively, and FP and Fpos can be updated if the primer is a forward primer, and RP and Rpos can be updated if the primer is a reverse primer. Also, whenever sid changes, FPoffset and RPoffset can be updated.

Pair Filtering 및 Scoring 단계는 정방향 프라이머와 역방향 프라이머의 모든 가능한 쌍에 대한 연산을 수행해야 하기 때문에 모든 가능한 쌍에 페널티 점수를 저장할 수 있는 score 배열을 생성할 수 있다. 이 score 배열의 예시는 도 12의 (d)에 나타나 있다. 도 12의 (d)의 scoreoffset은 score에 대한 포인터 배열로 사용되며, (b)의 FPoffset과 (c)의 RPoffset을 한번 스캔함으로써 생성될 수 있다. score 배열의 경우 그 크기가 매우 크기 때문에 일반적으로 GPU에 한번에 복사될 수 없다. 따라서 한번에 복사될 수 있는 크기만큼만 scoreoffset과 score 배열을 생성하고 일치하는 프라이머 쌍이 '타당하지 않음'을 뜻하는 '-1.0'으로 초기화할 수 있다. 이 때, 이후 GPU에서 수행되는 연산은 sid 별로 독립적이기 때문에 하나의 sid 내의 모든 정방향 및 역방향 프라이머는 같은 GPU에 한번에 복사되어야 한다(S1104).Since pair filtering and scoring steps must perform calculations on all possible pairs of forward and reverse primers, a score array capable of storing penalty scores for all possible pairs can be generated. An example of this score array is shown in FIG. 12(d). The scoreoffset in (d) of FIG. 12 is used as a pointer array for scores, and can be generated by scanning FPoffset in (b) and RPoffset in (c) once. In the case of the score array, its size is very large, so it usually cannot be copied to the GPU at once. Therefore, a scoreoffset and a score array can be generated only as large as the size that can be copied at one time, and the matching primer pair can be initialized to '-1.0', which means 'not valid'. At this time, since operations performed in the GPU are independent for each sid, all forward and reverse primers within one sid must be copied to the same GPU at once (S1104).

생성된 score 및 scoreoffset와 해당 score에 대한 arraysFP, arraysRP를 GPU에 복사하여 GPU 내에서 동일한 sid를 가지는 정방향 프라이머와 역방향 프라이머에 대해 조인 계산을 수행할 수 있다(S1105, S1106). By copying the generated score and scoreoffset and arraysFP and arraysRP for the corresponding score to the GPU, a join calculation can be performed on the forward and reverse primers having the same sid in the GPU (S1105, S1106).

이 때, 상기 도 8에 나타난 General Cross-Hybridization Filtering에서처럼 현재 GPU 내에서 가지고 있는 데이터 구조에 대한 조인 연산과 그 다음 연산에 수행될 score에 대한 배열을 준비하고 복사하는 단계는 비동기적으로 이루어지기 때문에 S1105 단계에서 데이터 구조의 GPU로의 복사 또한 스트리밍 복사로 수행될 수 있다. At this time, as in the General Cross-Hybridization Filtering shown in FIG. 8, the join operation for the data structure currently in the GPU and the step of preparing and copying an array of scores to be performed in the next operation are performed asynchronously. Copying of the data structure to the GPU in step S1105 may also be performed by streaming copying.

조인 연산에서는 5 개의 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용할 수 있다. 조건에는 S1107 단계 내지 S1111 단계에서와 같이 온도 차이, 길이 차이, Pair-Complementary, 3' End Pair-Complementary, 생성물의 길이 차이에 대해 순차적으로 검사할 수 있다. 이 값들은 모두 프로그램이 실행될 때, 사용자에 의해 정의될 수 있다. In the join operation, 5 pair primer filtering conditions can be applied. Conditions can be sequentially inspected for temperature difference, length difference, Pair-Complementary, 3' End Pair-Complementary, and product length difference as in steps S1107 to S1111. All of these values can be defined by the user when the program is running.

그리고 모든 쌍 프라이머 필터링(Pair Primer Filtering) 조건들을 모두 만족한 프라이머 쌍에 대해서는 정방향, 역박향 프라이머 각각에 대해 페널티 점수(Single Primer Penalty)를 계산하여 두 페널티 점수의 합을 바탕으로 쌍 프라이머 페널티 점수(Pair Primer Penalty)를 계산하여 일치하는 score의 위치에 페널티 점수를 기록할 수 있다(S1112).And, for primer pairs that satisfy all the Pair Primer Filtering conditions, a penalty score (Single Primer Penalty) is calculated for each of the forward and reverse primers, and based on the sum of the two penalty scores, the pair primer penalty score ( Pair Primer Penalty) can be calculated and the penalty score can be recorded at the location of the matching score (S1112).

상기 정방향 및 역방향 프라이머에 대한 페널티 점수(Single Primer Penalty)의 경우 상기 언급했던 싱글 프라이머 필터링(Single Primer Filtering) 조건들에 대해 페널티를 계산한 것으로, 길이, 온도(℃), GC content(%), Self-Complementarity, 3' End Self-Complementary, 연속된 염기, end stability(G value)가 해당된다.In the case of the penalty score for the forward and reverse primers (Single Primer Penalty), the penalty was calculated for the single primer filtering conditions mentioned above, length, temperature (℃), GC content (%), Self-Complementarity, 3' End Self-Complementary, consecutive bases, and end stability (G value) are applicable.

쌍 프라이머 페널티 점수(Pair Primer Penalty)는 정방향 및 역방향 프라이머에 대한 페널티 점수의 합과 상기 언급했던 쌍 프라이머 필터링(Pair Primer Filtering) 조건들을 사용해 계산된다. The Pair Primer Penalty is calculated using the sum of the penalty scores for the forward and reverse primers and the Pair Primer Filtering conditions mentioned above.

GPU에 복사된 정방향 프라이머와 역방향 프라이머 사이의 조인이 끝나면 최종 scoreoffset과 score 배열을 호스트로 복사할 수 있다(S1113).After the join between the forward and reverse primers copied to the GPU is finished, the final scoreoffset and score array can be copied to the host (S1113).

복사된 score 배열을 읽으면서 쌍 프라이머 페널티 점수가 '-1.0'이 아닌 양의 값을 가지는 프라이머 쌍에 대해 공통되는 sidset을 구하여 최종 결과를 출력할 수 있다. 최종 결과물의 포맷은 '공통sidsetÅf.PÅr.P sidÅf.posÅr.pos' 이다. 여기서 f.P는 정방향 프라이머를, r.P는 역방향 프라이머를 뜻하며, f.pos과 r.pos은 각각 정방향 프라이머와 역방향 프라이머의 pos을 뜻한다(S1114).While reading the copied score array, a common sidset for a primer pair having a positive pair primer penalty score other than '-1.0' can be obtained and the final result can be output. The format of the final result is 'common sidsetÅf.PÅr.P sidÅf.posÅr.pos'. Here, f.P denotes a forward primer, r.P denotes a reverse primer, and f.pos and r.pos denote the pos of the forward and reverse primers, respectively (S1114).

아직 연산하지 않은 arraysFP와 srraysrP가 남아있다면 S1104 단계로 돌아가 scoreoffset 배열과 score를 재생성 및 초기화 한 후 모든 sid에 대한 페어 연산이 끝날 때까지 S1105 단계 내지 S1114 단계를 반복할 수 있다. score 배열에 대한 데이터 준비 및 복사와 GPU 내에서의 연산이 비동기적으로 이루어지기는 하지만 해당 단계의 경우 상기 도 8에 나타난 General Cross-Hybridization Filtering와는 달리 매번 score 결과를 호스트로 복사하여 결과를 출력하여야 하기 때문에 스트리밍 복사를 활용했을 때 얻을 수 있는 성능 향상의 효과가 상대적으로 작다.If there are arraysFP and srraysrP that have not yet been calculated, return to step S1104 to regenerate and initialize the scoreoffset array and score, and then repeat steps S1105 to S1114 until pair calculations for all sids are completed. Although the data preparation and copying of the score array and the operation in the GPU are performed asynchronously, in this step, unlike the General Cross-Hybridization Filtering shown in FIG. 8, the score result must be copied to the host every time to output the result. Therefore, the performance improvement that can be obtained when using streaming copy is relatively small.

또한, GPU 내에서 연산을 수행할 때 한 키(sid)에 대한 프라이머 개수의 분포가 상기 도 8에 나타난 General Cross-Hybridization Filtering에서의 분포보다 훨씬 더 스큐(Skew) 되었기 때문에 해당 단계에서는 스레숄드를 smallThreshold와 largeThreshold, 두 개를 설정하고, smallThrehold 이하의 인덱스를 가지는 경우 each-thread mode를, smallThreshold와 largeThreshold 사이의 인덱스를 가지는 경우 block-threads mode를 적용하고, largeThreshold 보다 큰 인덱스를 가지는 경우 모든 GPU 쓰레드가 하나의 키를 처리하는 all-threads 모드를 적용함으로써 작업부하 밸런싱을 처리할 수 있다.In addition, since the distribution of the number of primers for one key (sid) is much more skewed than the distribution in General Cross-Hybridization Filtering shown in FIG. and largeThreshold, two are set, each-thread mode is applied when the index is less than smallThreshold, block-threads mode is applied when the index is between smallThreshold and largeThreshold, and all GPU threads are applied when the index is greater than largeThreshold. Workload balancing can be handled by applying the all-threads mode that processes one key.

이어, 도 3의 S311 단계에서는 상기 S310 단계에서 출력된 결과를 바탕으로 리눅스 소트(Linux Sort)를 이용해 sidset 그룹 별로 정렬하고, 각 그룹 내에서 페널티에 따라 프라이머 쌍에 순서를 부여한 후, 최종 결과를 얻게 된다. Subsequently, in step S311 of FIG. 3, based on the results output in step S310, sort by sidset group using Linux Sort, order the primer pairs according to the penalty within each group, and then the final result get it

본 실시예들에 따른 GPU를 활용한 대규모 DNA 서열 데이터베이스에 대해 특이성 조건을 만족하는 유효한 모든 프라이머들을 빠르게 디자인하는 방법은 실시예에 따라 설명하였지만, 본 발명의 범위는 특정 실시예에 한정되는 것은 아니며, 본 발명과 관련하여 통상의 지식을 가진 자에게 자명한 범위 내에서 여러 가지의 대안, 수정 및 변경하여 실시할 수 있다.A method for quickly designing all effective primers satisfying specificity conditions for a large-scale DNA sequence database using GPU according to the present embodiments has been described according to the examples, but the scope of the present invention is not limited to the specific examples. , Various alternatives, modifications and changes can be made and implemented within the scope obvious to those skilled in the art in relation to the present invention.

이상에서 설명된 장치는 하드웨어 구성요소, 소프트웨어 구성요소, 및/또는 하드웨어 구성요소 및 소프트웨어 구성요소의 조합으로 구현될 수 있다. 예를 들어, 실시예들에서 설명된 장치 및 구성요소는, 예를 들어, 프로세서, 컨트롤러, ALU(arithmetic logic unit), 디지털 신호 프로세서(digital signal processor), 마이크로컴퓨터, FPA(field programmable array), PLU(programmable logic unit), 마이크로프로세서, 또는 명령(instruction)을 실행하고 응답할 수 있는 다른 어떠한 장치와 같이, 하나 이상의 범용 컴퓨터 또는 특수 목적 컴퓨터를 이용하여 구현될 수 있다. 처리 장치는 운영 체제(OS) 및 상기 운영 체제 상에서 수행되는 하나 이상의 소프트웨어 애플리케이션을 수행할 수 있다. 또한, 처리 장치는 소프트웨어의 실행에 응답하여, 데이터를 접근, 저장, 조작, 처리 및 생성할 수도 있다. 이해의 편의를 위하여, 처리 장치는 하나가 사용되는 것으로 설명된 경우도 있지만, 해당 기술분야에서 통상의 지식을 가진 자는, 처리 장치가 복수 개의 처리 요소(processing element) 및/또는 복수 유형의 처리 요소를 포함할 수 있음을 알 수 있다. 예를 들어, 처리 장치는 복수 개의 프로세서 또는 하나의 프로세서 및 하나의 컨트롤러를 포함할 수 있다. 또한, 병렬 프로세서(parallel processor)와 같은, 다른 처리 구성(processing configuration)도 가능하다.The devices described above may be implemented as hardware components, software components, and/or a combination of hardware components and software components. For example, devices and components described in the embodiments may include, for example, a processor, a controller, an arithmetic logic unit (ALU), a digital signal processor, a microcomputer, a field programmable array (FPA), It may be implemented using one or more general purpose or special purpose computers, such as a programmable logic unit (PLU), microprocessor, or any other device capable of executing and responding to instructions. A processing device may run an operating system (OS) and one or more software applications running on the operating system. A processing device may also access, store, manipulate, process, and generate data in response to execution of software. For convenience of understanding, there are cases in which one processing device is used, but those skilled in the art will understand that the processing device includes a plurality of processing elements and/or a plurality of types of processing elements. It can be seen that it can include. For example, a processing device may include a plurality of processors or a processor and a controller. Other processing configurations are also possible, such as parallel processors.

소프트웨어는 컴퓨터 프로그램(computer program), 코드(code), 명령(instruction), 또는 이들 중 하나 이상의 조합을 포함할 수 있으며, 원하는 대로 동작하도록 처리 장치를 구성하거나 독립적으로 또는 결합적으로(collectively) 처리 장치를 명령할 수 있다. 소프트웨어 및/또는 데이터는, 처리 장치에 의하여 해석되거나 처리 장치에 명령 또는 데이터를 제공하기 위하여, 어떤 유형의 기계, 구성요소(component), 물리적 장치, 가상 장치(virtual equipment), 컴퓨터 저장 매체 또는 장치에 구체화(embody)될 수 있다. 소프트웨어는 네트워크로 연결된 컴퓨터 시스템 상에 분산되어서, 분산된 방법으로 저장되거나 실행될 수도 있다. 소프트웨어 및 데이터는 하나 이상의 컴퓨터 판독 가능 기록 매체에 저장될 수 있다.Software may include a computer program, code, instructions, or a combination of one or more of the foregoing, which configures a processing device to operate as desired or processes independently or collectively. The device can be commanded. Software and/or data may be any tangible machine, component, physical device, virtual equipment, computer storage medium or device, intended to be interpreted by or provide instructions or data to a processing device. can be embodied in Software may be distributed on networked computer systems and stored or executed in a distributed manner. Software and data may be stored on one or more computer readable media.

실시예에 따른 방법은 다양한 컴퓨터 수단을 통하여 수행될 수 있는 프로그램 명령 형태로 구현되어 컴퓨터 판독 가능 매체에 기록될 수 있다. 상기 컴퓨터 판독 가능 매체는 프로그램 명령, 데이터 파일, 데이터 구조 등을 단독으로 또는 조합하여 포함할 수 있다. 상기 매체에 기록되는 프로그램 명령은 실시예를 위하여 특별히 설계되고 구성된 것들이거나 컴퓨터 소프트웨어 당업자에게 공지되어 사용 가능한 것일 수도 있다. 컴퓨터 판독 가능 기록 매체의 예에는 하드 디스크, 플로피 디스크 및 자기 테이프와 같은 자기 매체(magnetic media), CD-ROM, DVD와 같은 광기록 매체(optical media), 플롭티컬 디스크(floptical disk)와 같은 자기-광 매체(magneto-optical media), 및 롬(ROM), 램(RAM), 플래시 메모리 등과 같은 프로그램 명령을 저장하고 수행하도록 특별히 구성된 하드웨어 장치가 포함된다. 프로그램 명령의 예에는 컴파일러에 의해 만들어지는 것과 같은 기계어 코드뿐만 아니라 인터프리터 등을 사용해서 컴퓨터에 의해서 실행될 수 있는 고급 언어 코드를 포함한다. The method according to the embodiment may be implemented in the form of program instructions that can be executed through various computer means and recorded on a computer readable medium. The computer readable medium may include program instructions, data files, data structures, etc. alone or in combination. Program commands recorded on the medium may be specially designed and configured for the embodiment or may be known and usable to those skilled in computer software. Examples of computer-readable recording media include magnetic media such as hard disks, floppy disks and magnetic tapes, optical media such as CD-ROMs and DVDs, and magnetic media such as floptical disks. - includes hardware devices specially configured to store and execute program instructions, such as magneto-optical media, and ROM, RAM, flash memory, and the like. Examples of program instructions include high-level language codes that can be executed by a computer using an interpreter, as well as machine language codes such as those produced by a compiler.

이상과 같이 실시예들이 비록 한정된 실시예와 도면에 의해 설명되었으나, 해당 기술분야에서 통상의 지식을 가진 자라면 상기의 기재로부터 다양한 수정 및 변형이 가능하다. 예를 들어, 설명된 기술들이 설명된 방법과 다른 순서로 수행되거나, 및/또는 설명된 시스템, 구조, 장치, 회로 등의 구성요소들이 설명된 방법과 다른 형태로 결합 또는 조합되거나, 다른 구성요소 또는 균등물에 의하여 대치되거나 치환되더라도 적절한 결과가 달성될 수 있다.As described above, although the embodiments have been described with limited examples and drawings, those skilled in the art can make various modifications and variations from the above description. For example, the described techniques may be performed in an order different from the method described, and/or components of the described system, structure, device, circuit, etc. may be combined or combined in a different form than the method described, or other components may be used. Or even if it is replaced or substituted by equivalents, appropriate results can be achieved.

그러므로, 다른 구현들, 다른 실시예들 및 특허청구범위와 균등한 것들도 후술하는 특허청구범위의 범위에 속한다.Therefore, other implementations, other embodiments, and equivalents of the claims are within the scope of the following claims.

Claims (15)

GPU 프라이머를 활용하여 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 프라이머들을 디자인하기 위한 전체적인 연산을 수행하며, 연산 과정에서 생성하는 해쉬맵을 포함하는 데이터 구조는 메인 메모리에 저장하여 사용하고, 초기 입력으로 사용되는 상기 DNA 서열 데이터베이스 및 후보 프라이머들을 기록하는 중간과정의 파일의 경우 별도의 하드디스크에 파일 형태로 저장해두고 필요한 경우 읽어와 사용하는 CPU; 및
대규모 연산을 필요로 하는 경우에 상기 CPU를 통해 상기 GPU 프라이머의 일부 연산에 대한 명령을 전달 받아 구동되며, GPU 메모리는 상기 메인 메모리로부터 연산에 필요한 데이터를 복사 받아 커널 연산을 수행한 뒤 그 결과에 대해 상기 메인 메모리로 다시 복사하는 GPU
를 포함하고,
상기 CPU 및 상기 GPU를 통해 상기 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 프라이머들을 디자인하며,
상기 CPU에서 주어진 DNA 서열 데이터베이스와 싱글 프라이머 필터링(Single Primer Filtering) 조건 및 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 입력 받아, 최소길이와 최대길이 사이의 부분서열들을 추출하여 후보 프라이머들을 생성하여 출력하는 제1 단계;
출력된 상기 후보 프라이머들에 대해 입력 받은 상기 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여, 조건을 만족하는 프라이머들을 이용하여 연산에 사용될 데이터 구조인 해쉬맵을 생성하는 제2 단계;
추출된 상기 부분서열들을 기록한 C1' 파일과 상기 제2 단계에서 상기 싱글 프라이머 필터링(Single Primer Filtering) 조건을 통과해 상기 해쉬맵에 저장된 프라이머를 바탕으로 페어조인을 수행하여, 상기 프라이머가 5' 끝부분을 제외하고 나머지 부분이 동일한 경우, 상기 프라이머의 상기 해쉬맵 내의 valid 값을 업데이트 하도록 5' Cross-Hybridization Filtering을 적용하는 제3 단계;
추출된 상기 부분서열들을 기록한 C1' 파일과 상기 제2 단계에서의 상기 싱글 프라이머 필터링(Single Primer Filtering) 및 상기 제3 단계에서의 상기 5' Cross-Hybridization Filtering을 통과한 후보 프라이머 세트를 이용해 GPU 연산에서 사용할 데이터 구조를 생성하고, 상기 GPU 내에서 페어조인을 수행하여 각각의 후보 프라이머 세트에 있는 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지 부분이 동일한 경우, 상기 프라이머의 상기 해쉬맵 내의 valid 값을 업데이트 하는 제4 단계; 및
상기 제4 단계 결과에서 남아 있는 상기 프라이머를 정방향 프라이머와 역방향 프라이머 세트로 각각 나누어 각각에 대한 데이터 구조를 생성하고, 상기 GPU 내에서 셀프조인 연산을 수행하여 상기 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용하고, 조건을 만족한 프라이머 쌍에 대해 페널티 점수를 계산하여 출력하고, 같은 sidset 그룹 내에서 페널티 점수에 따라 순차 정렬하는 제5 단계
를 수행하며,
상기 제4 단계는,
싱글 프라이머 필터링(Single Primer Filtering)과 5' Cross-Hybridization Filtering을 모두 통과한 프라이머가 저장된 해쉬맵으로부터 프라이머를 여러 개의 시드(seed)로 나누어 또 다른 해쉬맵을 생성하고, 상기 또 다른 해쉬맵으로부터 상기 싱글 프라이머 필터링(Single Primer Filtering) 및 5' Cross-Hybridization Filtering을 모두 통과한 프라이머에 대한 정보를 가지는 데이터 구조 arraysC3와 주어진 DNA 서열 데이터베이스에 추출된 모든 가능한 부분서열에 대한 정보를 가지는 데이터 구조 arraysC1을 생성하며, 생성한 데이터 구조를 상기 GPU에 복사하여 arraysC1과 arraysC3의 페어조인을 수행하면서 각각의 세트 내의 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지가 동일한 경우, arraysC3의 프라이머에 대해 '타당하지 않음'을 나타내도록 업데이트 하는 것
을 특징으로 하는, 장치.
Using GPU primers, overall calculations are performed to design effective primers that satisfy both primer restriction and specificity conditions in the DNA sequence database, and the data structure including the hash map generated during the calculation process is stored in the main memory for use. and, in the case of intermediate process files for recording the DNA sequence database and candidate primers used as initial inputs, stored in the form of files on a separate hard disk and read and used if necessary; and
When a large-scale operation is required, it is driven by receiving commands for some operations of the GPU primer through the CPU, and the GPU memory copies data necessary for operation from the main memory, performs kernel operation, and then displays the result. GPU to copy back to the main memory for
including,
Design effective primers that simultaneously satisfy primer restriction conditions and specificity conditions in the DNA sequence database through the CPU and the GPU,
Receiving the DNA sequence database given by the CPU and the Single Primer Filtering conditions and Pair Primer Filtering conditions, extracting subsequences between the minimum length and the maximum length to generate and output candidate primers first step;
a second step of applying the single primer filtering condition received to the output candidate primers and generating a hash map, which is a data structure to be used for calculation, using primers satisfying the condition;
Pair-joining is performed based on the C1' file recording the extracted subsequences and the primers stored in the hash map that have passed the Single Primer Filtering condition in the second step, so that the primers are located at the 5' end A third step of applying 5' Cross-Hybridization Filtering to update a valid value in the hash map of the primer when the remaining parts are the same except for the part;
GPU calculation using the C1' file recording the extracted subsequences and the candidate primer set that passed the Single Primer Filtering in the second step and the 5' Cross-Hybridization Filtering in the third step. Creates a data structure to be used in the GPU, and performs pair join in the GPU, and when the primers in each candidate primer set are the same except for the given mismatch number (#mismatch), the valid value of the primer in the hash map A fourth step of updating; and
The primers remaining in the result of the fourth step are divided into a forward primer and a reverse primer set, respectively, to create a data structure for each, and to perform a self-join operation in the GPU to determine the pair primer filtering condition. A fifth step of applying, calculating and outputting penalty scores for primer pairs that satisfy the condition, and sequentially sorting according to penalty scores within the same sidset group
to perform,
The fourth step,
From the hash map in which the primers that have passed both Single Primer Filtering and 5' Cross-Hybridization Filtering are stored, another hash map is created by dividing the primers into several seeds, and from the other hash map Create data structure arraysC3, which contains information on primers that have passed both Single Primer Filtering and 5' Cross-Hybridization Filtering, and data structure arraysC1, which contains information on all possible subsequences extracted from a given DNA sequence database and copying the generated data structure to the GPU to perform pair-joining of arraysC1 and arraysC3, and if the primers in each set are the same except for the given number of mismatches (#mismatch), the primers in arraysC3 are not valid. to update to indicate '
Characterized by a device.
삭제delete 제1항에 있어서,
상기 CPU는,
상기 제1 단계에서 상기 DNA 데이터베이스를 서열 번호인 sid와 서열 데이터 S를 sid+S의 쌍의 형태로 입력 받고, 이후에 사용될 필터링 조건들을 입력 받아 모든 가능한 최소길이와 최대길이 사이의 상기 부분서열을 추출하여 후보 프라이머들을 생성하고, 출력된 상기 후보 프라이머들에 대해 역방향 상보적 프라이머를 만들어 역방향 프라이머를 표시하면 추출하며, 동일한 프라이머가 나타나는 sid의 집합인 sidset을 생성하는 것
을 특징으로 하는, 장치.
According to claim 1,
The CPU,
In the first step, the DNA database receives the sequence number sid and the sequence data S in the form of a pair of sid + S, inputs the filtering conditions to be used later, and calculates the subsequence between all possible minimum lengths and maximum lengths Extracting to generate candidate primers, making reverse complementary primers for the output candidate primers, extracting when reverse primers are displayed, and generating a sidset, which is a set of sids in which the same primers appear
Characterized by a device.
제1항에 있어서,
상기 CPU는,
상기 제2 단계에서 복수개의 상기 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여 조건을 만족하는 상기 프라이머에 대해서만 상기 해쉬맵을 생성하여 저장하는 것
을 특징으로 하는, 장치.
According to claim 1,
The CPU,
In the second step, a plurality of single primer filtering conditions are applied to generate and store the hash map only for the primers that satisfy the condition.
Characterized by a device.
제4항에 있어서,
상기 복수개의 싱글 프라이머 필터링(Single Primer Filtering) 조건은,
길이, 온도(
Figure 112020120544080-pat00014
, GC content(%), Self-Complementarity, 3' End Self-Complementary, 연속된 염기 및 end stability(G value)인 것
을 특징으로 하는, 장치.
According to claim 4,
The plurality of single primer filtering conditions,
length, temperature (
Figure 112020120544080-pat00014
, GC content (%), Self-Complementarity, 3' End Self-Complementary, contiguous bases and end stability (G value)
Characterized by a device.
삭제delete 제1항에 있어서,
상기 GPU는,
상기 제5 단계에서 생성된 정방향 프라이머와 역방향 프라이머 세트로 각각 나누어 각각에 대한 데이터 구조를 복사하여 상기 GPU 내에서 같은 sid 내의 정방향 프라이머와 역방향 프라이머 사이의 페어조인 연산을 수행하며, 복수개의 상기 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용해 조건을 만족하는 프라이머에 대해서만 상기 페널티 점수를 계산하여 저장하고, 상기 페널티 점수가 저장된 데이터 구조를 상기 메인 메모리로 복사해 결과물을 출력하는 것
을 특징으로 하는, 장치.
According to claim 1,
The GPU,
Divide into forward and reverse primer sets generated in the fifth step, copy the data structure for each, and perform a pair-join operation between the forward and reverse primers in the same sid in the GPU, and a plurality of the paired primers Applying filtering (Pair Primer Filtering) conditions to calculate and store the penalty score only for primers that satisfy the condition, and copy the data structure in which the penalty score is stored to the main memory to output the result
Characterized by a device.
컴퓨터 장치를 통해 구현되는 GPU를 활용하여 DNA 서열 데이터베이스에서 프라이머 제한 조건과 특이성 조건을 동시에 만족하는 유효한 프라이머들을 디자인하는 방법에 있어서,
주어진 DNA 서열 데이터베이스와 싱글 프라이머 필터링(Single Primer Filtering) 조건 및 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 입력 받아, 최소길이와 최대길이 사이의 부분서열들을 추출하여 후보 프라이머들을 생성하여 출력하는 제1 단계;
출력된 상기 후보 프라이머들에 대해 입력 받은 상기 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여, 조건을 만족하는 프라이머들을 이용하여 연산에 사용될 데이터 구조인 해쉬맵을 생성하는 제2 단계;
추출된 상기 부분서열들을 기록한 C1' 파일과 상기 제2 단계에서 상기 싱글 프라이머 필터링(Single Primer Filtering) 조건을 통과해 상기 해쉬맵에 저장된 프라이머를 바탕으로 페어조인을 수행하여, 상기 프라이머가 5' 끝부분을 제외하고 나머지 부분이 동일한 경우, 상기 프라이머의 상기 해쉬맵 내의 valid 값을 업데이트 하도록 5' Cross-Hybridization Filtering을 적용하는 제3 단계;
추출된 상기 부분서열들을 기록한 C1' 파일과 상기 제2 단계에서의 상기 싱글 프라이머 필터링(Single Primer Filtering) 및 상기 제3 단계에서의 상기 5' Cross-Hybridization Filtering을 통과한 후보 프라이머 세트를 이용해 GPU 연산에서 사용할 데이터 구조를 생성하고, GPU 내에서 페어조인을 수행하여 각각의 후보 프라이머 세트에 있는 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지 부분이 동일한 경우, 상기 프라이머의 상기 해쉬맵 내의 valid 값을 업데이트 하는 제4 단계; 및
상기 제4 단계 결과에서 남아 있는 상기 프라이머를 정방향 프라이머와 역방향 프라이머 세트로 각각 나누어 각각에 대한 데이터 구조를 생성하고, 상기 GPU 내에서 셀프조인 연산을 수행하여 상기 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용하고, 조건을 만족한 프라이머 쌍에 대해 페널티 점수를 계산하여 출력하고, 같은 sidset 그룹 내에서 페널티 점수에 따라 순차 정렬하는 제5 단계
를 포함하고,
상기 제4 단계는,
싱글 프라이머 필터링(Single Primer Filtering)과 5' Cross-Hybridization Filtering을 모두 통과한 프라이머가 저장된 해쉬맵으로부터 프라이머를 여러 개의 시드(seed)로 나누어 또 다른 해쉬맵을 생성하는 단계;
상기 또 다른 해쉬맵으로부터 상기 싱글 프라이머 필터링(Single Primer Filtering) 및 5' Cross-Hybridization Filtering을 모두 통과한 프라이머에 대한 정보를 가지는 데이터 구조 arraysC3와 주어진 DNA 서열 데이터베이스에 추출된 모든 가능한 부분서열에 대한 정보를 가지는 데이터 구조 arraysC1을 생성하는 단계; 및
생성한 데이터 구조를 상기 GPU에 복사하여 arraysC1과 arraysC3의 페어조인을 수행하면서 각각의 세트 내의 프라이머가 주어진 불일치수(#mismatch)를 제외한 나머지가 동일한 경우, arraysC3의 프라이머에 대해 '타당하지 않음'을 나타내도록 업데이트 하는 단계
를 포함하는, 방법.
A method for designing effective primers that simultaneously satisfy primer restriction conditions and specificity conditions in a DNA sequence database using a GPU implemented through a computer device,
A first step of generating and outputting candidate primers by extracting subsequences between a minimum length and a maximum length by receiving a given DNA sequence database and Single Primer Filtering conditions and Pair Primer Filtering conditions as inputs. ;
a second step of applying the single primer filtering condition received to the output candidate primers and generating a hash map, which is a data structure to be used for calculation, using primers satisfying the condition;
Pair-joining is performed based on the C1' file recording the extracted subsequences and the primers stored in the hash map that have passed the Single Primer Filtering condition in the second step, so that the primers are located at the 5' end A third step of applying 5' Cross-Hybridization Filtering to update a valid value in the hash map of the primer when the remaining parts are the same except for the part;
GPU calculation using the C1' file recording the extracted subsequences and the candidate primer set that passed the Single Primer Filtering in the second step and the 5' Cross-Hybridization Filtering in the third step. Create a data structure to be used in the GPU, and perform pair-joining in the GPU, and if the primers in each candidate primer set are the same except for the given mismatch number (#mismatch), the valid value in the hash map of the primer The fourth step of updating; and
The primers remaining in the result of the fourth step are divided into a forward primer and a reverse primer set, respectively, to create a data structure for each, and to perform a self-join operation in the GPU to determine the pair primer filtering condition. A fifth step of applying, calculating and outputting penalty scores for primer pairs that satisfy the condition, and sequentially sorting according to penalty scores within the same sidset group
including,
In the fourth step,
Generating another hash map by dividing the primers into several seeds from the hash map in which the primers that have passed both single primer filtering and 5' cross-hybridization filtering are stored;
Data structure arraysC3 having information on primers that have passed both the Single Primer Filtering and 5' Cross-Hybridization Filtering from the another hash map and information on all possible subsequences extracted from a given DNA sequence database Creating a data structure arraysC1 having; and
Copying the generated data structure to the GPU and performing pair-joining of arraysC1 and arraysC3, and when the primers in each set are the same except for the given number of mismatches (#mismatch), 'not valid' for the primers in arraysC3 Steps to update to indicate
Including, method.
제8항에 있어서,
상기 제1 단계는,
상기 DNA 데이터베이스를 서열 번호인 sid와 서열 데이터 S를 sid+S의 쌍의 형태로 입력 받고, 이후에 사용될 필터링 조건들을 입력 받아 모든 가능한 최소길이와 최대길이 사이의 상기 부분서열을 추출하여 후보 프라이머들을 생성하는 단계; 및
출력된 상기 후보 프라이머들에 대해 역방향 상보적 프라이머를 만들어 역방향 프라이머를 표시하면 추출하는 단계
를 포함하고,
동일한 프라이머가 나타나는 sid의 집합인 sidset을 생성하는 것을 특징으로 하는, 방법.
According to claim 8,
The first step is
The DNA database receives sequence number sid and sequence data S in the form of a pair of sid + S, inputs filtering conditions to be used later, extracts the subsequence between all possible minimum and maximum lengths, and selects candidate primers. generating; and
Making reverse complementary primers for the output candidate primers and extracting the reverse primers when indicated.
including,
A method characterized by generating a sidset, which is a set of sids in which the same primer appears.
제8항에 있어서,
상기 제2 단계는,
복수개의 상기 싱글 프라이머 필터링(Single Primer Filtering) 조건을 적용하여 조건을 만족하는 상기 프라이머에 대해서만 상기 해쉬맵을 생성하여 저장하는 것
을 특징으로 하는, 방법.
According to claim 8,
The second step,
Applying a plurality of single primer filtering conditions to generate and store the hash map only for the primers that satisfy the condition
Characterized by, method.
제10항에 있어서,
상기 복수개의 싱글 프라이머 필터링(Single Primer Filtering) 조건은,
길이, 온도(
Figure 112020120544080-pat00015
, GC content(%), Self-Complementarity, 3' End Self-Complementary, 연속된 염기 및 end stability(G value)인 것
을 특징으로 하는, 방법.
According to claim 10,
The plurality of single primer filtering conditions,
length, temperature (
Figure 112020120544080-pat00015
, GC content (%), Self-Complementarity, 3' End Self-Complementary, contiguous bases and end stability (G value)
Characterized by, method.
제8항에 있어서,
상기 제3 단계는,
주어진 DNA 서열 데이터베이스에서 추출된 모든 가능한 상기 부분서열이 저장된 C1' 파일과 상기 싱글 프라이머 필터링(Single Primer Filtering)을 통과한 후보 프라이머가 저장된 상기 해쉬맵으로부터 페어조인을 수행하여, 각 세트의 프라이머가 5' 끝부분을 제외하고 나머지 부분이 동일한 경우, 상기 해쉬맵에 저장된 프라이머가 '타당하지 않음'을 나타내도록 업데이트 하는 단계
를 포함하는, 방법.
According to claim 8,
The third step,
Pair-joining is performed from the C1' file in which all possible subsequences extracted from a given DNA sequence database are stored and the hash map in which candidate primers that have passed the Single Primer Filtering are stored, so that the primers of each set are 5 ' Updating the primer stored in the hash map to indicate 'invalid' if the rest of the parts are the same except for the end.
Including, method.
삭제delete 제8항에 있어서,
상기 제5 단계는,
동일한 sid를 가지는 후보 프라이머를 그룹화하여 프라이머 개수가 작은 순으로 정렬하는 단계;
정렬한 파일을 입력으로 받아 후보 프라이머를 DNA 서열 데이터베이스에서 추출할 때 수행했던 표시의 유무에 따라 정방향 프라이머와 역방향 프라이머 두 세트로 분리하여 각각에 대해 GPU 연산에 사용될 데이터 구조를 생성하고 페널티 점수를 저장할 수 있는 데이터 구조를 생성하는 단계;
생성된 상기 데이터 구조를 상기 GPU에 복사하여 상기 GPU 내에서 같은 sid 내의 정방향 프라이머와 역방향 프라이머 사이의 페어조인 연산을 수행하며 복수개의 상기 쌍 프라이머 필터링(Pair Primer Filtering) 조건을 적용해 조건을 만족하는 프라이머에 대해서만 상기 페널티 점수를 계산하여 저장하는 단계; 및
상기 페널티 점수가 저장된 데이터 구조를 메인 메모리로 복사해 결과물을 출력하고 동일한 sidset을 기준으로 그룹화 하여, 각 sidset에서 상기 페널티 점수를 이용해 프라이머 쌍의 순서를 부여해 정렬하는 단계
를 포함하는, 방법.
According to claim 8,
The fifth step,
grouping candidate primers having the same sid and arranging them in descending order of the number of primers;
Receives the sorted file as an input and separates the candidate primers into two sets of forward and reverse primers according to the presence or absence of the mark performed when extracting the candidate primers from the DNA sequence database, creates a data structure to be used for GPU operation for each set, and stores penalty scores. Creating a data structure that can be;
Copy the generated data structure to the GPU, perform a pair-join operation between forward primers and reverse primers within the same sid in the GPU, and apply a plurality of the pair primer filtering conditions to satisfy the condition calculating and storing the penalty score only for the primer; and
Copying the data structure in which the penalty score is stored to the main memory, outputting the result, grouping based on the same sidset, and assigning an order to primer pairs using the penalty score in each sidset and sorting step
Including, method.
제14항에 있어서,
상기 복수개의 쌍 프라이머 필터링(Pair Primer Filtering) 조건은,
길이 차이, 온도 차이, 생성물의 길이, Pair-Complementary 및 3' End Pair-Complementary를 포함하는 것
을 특징으로 하는, 방법.
According to claim 14,
The plurality of pair primer filtering conditions are,
Including Length Difference, Temperature Difference, Product Length, Pair-Complementary and 3' End Pair-Complementary
Characterized by, method.
KR1020200149973A 2020-11-11 2020-11-11 Method and Apparatus for Rapidly Designing all Valid Primers that Simultaneously Satisfy Primer Restriction Condition and Specificity Condition in Large DNA Sequence Database using GPU KR102509751B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1020200149973A KR102509751B1 (en) 2020-11-11 2020-11-11 Method and Apparatus for Rapidly Designing all Valid Primers that Simultaneously Satisfy Primer Restriction Condition and Specificity Condition in Large DNA Sequence Database using GPU

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1020200149973A KR102509751B1 (en) 2020-11-11 2020-11-11 Method and Apparatus for Rapidly Designing all Valid Primers that Simultaneously Satisfy Primer Restriction Condition and Specificity Condition in Large DNA Sequence Database using GPU

Publications (2)

Publication Number Publication Date
KR20220063977A KR20220063977A (en) 2022-05-18
KR102509751B1 true KR102509751B1 (en) 2023-03-15

Family

ID=81800952

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1020200149973A KR102509751B1 (en) 2020-11-11 2020-11-11 Method and Apparatus for Rapidly Designing all Valid Primers that Simultaneously Satisfy Primer Restriction Condition and Specificity Condition in Large DNA Sequence Database using GPU

Country Status (1)

Country Link
KR (1) KR102509751B1 (en)

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101666506B1 (en) * 2015-04-15 2016-10-14 재단법인대구경북과학기술원 A method for the thorough design of valid and target-specific primers for large-scale DNA sequence database

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101889146B1 (en) * 2016-06-28 2018-08-17 재단법인대구경북과학기술원 Method for rapid design of valid high-quality primers and probes for multiple target genes in qPCR experiments

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101666506B1 (en) * 2015-04-15 2016-10-14 재단법인대구경북과학기술원 A method for the thorough design of valid and target-specific primers for large-scale DNA sequence database

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
B. Jia 외, "GLAPD: Whole Genome Based LAMP Primer Design for a Set of Target Genomes", Frontiers in Microbiology, 10:2860. (2019.12.13.)
H. Kim 외, "MRPrimer: a MapReduce-based method for the thorough design of valid and ranked primers for PCR", Nucleic Acids Research, 43(20):e130. (2015.06.24.)
H. Kim 외, "MRPrimerW: a tool for rapid design of valid high-quality primers for multiple target qPCR experiments", Nucleic Acids Research, 44(W1):W259-W266. (2016.05.06.)

Also Published As

Publication number Publication date
KR20220063977A (en) 2022-05-18

Similar Documents

Publication Publication Date Title
Shen et al. SeqKit: a cross-platform and ultrafast toolkit for FASTA/Q file manipulation
Pei et al. PROMALS3D: multiple protein sequence alignment enhanced with evolutionary and three-dimensional structural information
US9063914B2 (en) Systems and methods for transcriptome analysis
CN108985008B (en) Method and system for rapidly comparing gene data
US11286516B2 (en) Method for rapid design of valid high-quality primers and probes for multiple target genes in QPCR experiments
Brejová et al. Finding patterns in biological sequences
Xia et al. Fast protein structure comparison through effective representation learning with contrastive graph neural networks
KR101666506B1 (en) A method for the thorough design of valid and target-specific primers for large-scale DNA sequence database
Saini et al. Probabilistic expression of spatially varied amino acid dimers into general form of Chou׳ s pseudo amino acid composition for protein fold recognition
US20150248430A1 (en) Efficient encoding and storage and retrieval of genomic data
Soto et al. JACC-FPGA: A hardware accelerator for Jaccard similarity estimation using FPGAs in the cloud
Namiki et al. Acceleration of sequence clustering using longest common subsequence filtering
KR102509751B1 (en) Method and Apparatus for Rapidly Designing all Valid Primers that Simultaneously Satisfy Primer Restriction Condition and Specificity Condition in Large DNA Sequence Database using GPU
Shehab et al. A hybrid CPU-GPU implementation to accelerate multiple pairwise protein sequence alignment
Sahli et al. Arapan-S: a fast and highly accurate whole-genome assembly software for viruses and small genomes
Bae et al. GPrimer: a fast GPU-based pipeline for primer design for qPCR experiments
Xiao et al. EMS3: An improved algorithm for finding edit-distance based motifs
Cickovski et al. GPUDePiCt: a parallel implementation of a clustering algorithm for computing degenerate primers on graphics processing units
Anderson et al. An FPGA-based hardware accelerator supporting sensitive sequence homology filtering with profile hidden Markov models
Fortmann-Grote et al. RAREFAN: A webservice to identify REPINs and RAYTs in bacterial genomes
Daoud A note on the distance distribution paradigm for Mosaab-metric to process segmented genomes of influenza virus
Wang et al. Accelerating the Smith-Waterman algorithm by GPU for high-throughput sequence alignment
Kawam et al. A GPU-CPU heterogeneous algorithm for NGS read alignment
Otto et al. Phylogenetic footprinting and consistent sets of local aligments
Si et al. Survey of gene splicing algorithms based on reads

Legal Events

Date Code Title Description
E902 Notification of reason for refusal
E701 Decision to grant or registration of patent right