/
LRCorrectionProcess.h
74 lines (57 loc) · 1.59 KB
/
LRCorrectionProcess.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
//-----------------------------------------------
// Copyright 2011 Wellcome Trust Sanger Institute
// Written by Jared Simpson (js18@sanger.ac.uk)
// Released under the GPL
//-----------------------------------------------
//
// LRCorrectionProcess - Wrapper class implementing
// the long-read correction process
//
#ifndef LRCORRECTION_PROCESS_H
#define LRCORRECTION_PROCESS_H
#include <string>
#include "SequenceProcessFramework.h"
#include "BWT.h"
#include "SampledSuffixArray.h"
#include "LRAlignment.h"
// Parameters to the corrector
class LRCorrectionParameters
{
public:
const BWT* pBWT;
const BWT* pRBWT;
const SampledSuffixArray* pSSA;
LRAlignment::LRParams alignParams;
int minLength;
};
// Object holding the result of correcting one read
class LRCorrectionResult
{
public:
LRCorrectionResult() {}
// data
std::string correctedSequence;
};
//
class LRCorrectionProcess
{
public:
LRCorrectionProcess(const LRCorrectionParameters params);
~LRCorrectionProcess();
LRCorrectionResult process(const SequenceWorkItem& item);
private:
LRCorrectionParameters m_params;
};
// Write the results from the overlap step to an ASQG file
class LRCorrectionPostProcess
{
public:
LRCorrectionPostProcess(std::ostream* pCorrectedWriter);
~LRCorrectionPostProcess();
void process(const SequenceWorkItem& item, const LRCorrectionResult& result);
private:
std::ostream* m_pCorrectedWriter;
size_t m_readsKept;
size_t m_readsDiscarded;
};
#endif