CbmRoot
|
contains filling and updating of calibration histos More...
#include <CbmTofCalibrator.h>
Public Member Functions | |
CbmTofCalibrator () | |
virtual | ~CbmTofCalibrator () |
InitStatus | Init () |
Bool_t | InitParameters () |
Bool_t | CreateCalHist () |
void | FillCalHist (CbmTofHit *pHit, Int_t iOpt, CbmEvent *pEvent=NULL) |
void | FillHitCalHist (CbmTofHit *pHit, Int_t iOpt, CbmEvent *pEvent=NULL, TClonesArray *tHitColl=NULL) |
void | FillCalHist (CbmTofTracklet *pTrk, Int_t iOpt, CbmEvent *pEvent=NULL) |
Bool_t | UpdateCalHist (Int_t iOpt) |
void | ReadHist (TFile *fhFile) |
void | WriteHist (TFile *fhFile) |
void | HstDoublets (CbmTofTracklet *pTrk) |
double * | find_tofedge (const char *hname, Double_t dThr, Double_t dLen) |
double * | find_tofedge (const char *hname) |
double | CalcChi2 (TH1 *h1, TH1 *h2, int iShift) |
double * | fit_tofedge (const char *hname, Double_t dTmax, Double_t dThr) |
double * | fit_tofedge (const char *hname) |
double | TruncatedMeanY (TH2 *pHst, double RmsLim=1.) |
void | SetR0Lim (Double_t dVal) |
void | SetBeam (Bool_t bVal) |
Static Public Member Functions | |
static double | f1_tedge (double *x, double *par) |
Private Member Functions | |
CbmTofCalibrator (const CbmTofCalibrator &)=delete | |
CbmTofCalibrator | operator= (const CbmTofCalibrator &)=delete |
ClassDef (CbmTofCalibrator, 1) | |
Private Attributes | |
CbmDigiManager * | fDigiMan |
CbmTofEventClusterizer * | fTofClusterizer |
CbmTofFindTracks * | fTofFindTracks |
CbmTofTrackletTools * | fTrackletTools |
const std::vector< CbmTofDigi > * | fTofCalDigiVec = nullptr |
CbmTofDigiPar * | fDigiPar |
CbmTofDigiBdfPar * | fDigiBdfPar |
CbmTofGeoHandler * | fGeoHandler |
CbmTofDetectorId * | fTofId |
TClonesArray * | fTofDigiMatchColl |
FairEventHeader * | fEvtHeader |
TH1 * | fhCalR0 |
TH1 * | fhCalDX0 |
TH1 * | fhCalDY0 |
TH1 * | fhCalCounterDt |
TH1 * | fhCalCounterDy |
TH1 * | fhCalChannelDt |
TH1 * | fhCalChannelDy |
std::vector< TH2 * > | fhCalTot |
std::vector< TH2 * > | fhCalPosition |
std::vector< TH2 * > | fhCalPos |
std::vector< TH2 * > | fhCalTOff |
std::vector< TH2 * > | fhCalTofOff |
std::vector< TH2 * > | fhCalDelPos |
std::vector< TH2 * > | fhCalDelTOff |
std::vector< TH2 * > | fhCalCluTrms |
std::vector< TH2 * > | fhCalCluSize |
std::vector< TH2 * > | fhCalWalkAv |
std::vector< std::vector< std::vector< TH2 * > > > | fhCalWalk |
std::vector< std::vector< std::vector< TH2 * > > > | fhCalDtWalk |
std::vector< TH3 * > | fhCalXYTOff |
std::vector< TH3 * > | fhCalXYTot |
std::vector< std::vector< std::vector< TH3 * > > > | fhCalTotYWalk |
std::vector< std::vector< std::vector< TH3 * > > > | fhCalTotYTOff |
std::vector< TH1 * > | fhCorPos |
std::vector< TH1 * > | fhCorTOff |
std::vector< TH1 * > | fhCorTot |
std::vector< TH1 * > | fhCorTotOff |
std::vector< TH1 * > | fhCorSvel |
std::vector< std::vector< std::vector< TH1 * > > > | fhCorWalk |
std::map< UInt_t, UInt_t > | fDetIdIndexMap |
std::map< int, TH1 * > | fhDoubletDt |
std::map< int, TH1 * > | fhDoubletDd |
std::map< int, TH1 * > | fhDoubletV |
Double_t | fdR0Lim = 0. |
Bool_t | fbBeam = kFALSE |
contains filling and updating of calibration histos
Definition at line 51 of file CbmTofCalibrator.h.
CbmTofCalibrator::CbmTofCalibrator | ( | ) |
Constructor
Definition at line 54 of file CbmTofCalibrator.cxx.
|
virtual |
Destructor
Definition at line 93 of file CbmTofCalibrator.cxx.
|
privatedelete |
double CbmTofCalibrator::CalcChi2 | ( | TH1 * | h1, |
TH1 * | h2, | ||
int | iShift ) |
Definition at line 2248 of file CbmTofCalibrator.cxx.
Referenced by UpdateCalHist().
|
private |
Bool_t CbmTofCalibrator::CreateCalHist | ( | ) |
Definition at line 188 of file CbmTofCalibrator.cxx.
References fDetIdIndexMap, fDigiBdfPar, fDigiPar, fhCalChannelDt, fhCalChannelDy, fhCalCluSize, fhCalCluTrms, fhCalCounterDt, fhCalCounterDy, fhCalDelPos, fhCalDelTOff, fhCalDtWalk, fhCalDX0, fhCalDY0, fhCalPos, fhCalPosition, fhCalR0, fhCalTOff, fhCalTofOff, fhCalTot, fhCalTotYTOff, fhCalTotYWalk, fhCalWalk, fhCalWalkAv, fhCalXYTOff, fhCalXYTot, CbmTofDigiPar::GetCell(), CbmTofDigiBdfPar::GetDetUId(), CbmTofDigiBdfPar::GetNbChan(), CbmTofDigiBdfPar::GetNbDet(), CbmTofAddress::GetRpcId(), CbmTofCell::GetSizey(), CbmTofAddress::GetSmId(), CbmTofAddress::GetSmType(), CbmTofAddress::GetUniqueAddress(), nbClWalkBinX, and nbClWalkBinY.
Referenced by Init().
|
static |
Definition at line 359 of file CbmTofCalibrator.cxx.
References DetMask, fDetIdIndexMap, fDigiBdfPar, fDigiPar, fhCalPosition, fhCalTOff, fhCalTofOff, fhCalTot, fhCalXYTOff, fTofCalDigiVec, fTofClusterizer, fTofFindTracks, CbmHit::GetAddress(), CbmTofEventClusterizer::GetBeamAddr(), CbmTofDigiPar::GetCell(), CbmTofDigi::GetChannel(), CbmTofAddress::GetChannelId(), CbmTofEventClusterizer::GetHitPointer(), CbmLink::GetIndex(), CbmMatch::GetLink(), CbmTofEventClusterizer::GetMatchPointer(), CbmTofDigiBdfPar::GetNbChan(), CbmTofEventClusterizer::GetNbHits(), CbmMatch::GetNofLinks(), CbmTofHit::GetR(), CbmTofDigi::GetRpc(), CbmTofAddress::GetRpcId(), CbmTofDigi::GetSide(), CbmTofDigi::GetSm(), CbmTofAddress::GetSmId(), CbmTofAddress::GetSmType(), CbmHit::GetTime(), CbmTofDigi::GetTime(), CbmTofDigi::GetTot(), CbmTofFindTracks::GetTtTarg(), CbmTofDigi::GetType(), CbmPixelHit::GetX(), CbmPixelHit::GetY(), CbmHit::GetZ(), CbmTofEventClusterizer::MasterToLocal(), NevtH, pRef, and size().
Referenced by CbmTofEventClusterizer::Exec(), CbmTofFindTracks::FillHistograms(), and CbmTofEventClusterizer::FillHistos().
void CbmTofCalibrator::FillCalHist | ( | CbmTofTracklet * | pTrk, |
Int_t | iOpt, | ||
CbmEvent * | pEvent = NULL ) |
Definition at line 761 of file CbmTofCalibrator.cxx.
References CbmTofTracklet::ContainsAddr(), DetMask, fbBeam, fDetIdIndexMap, fDigiBdfPar, fDigiPar, fdR0Lim, fhCalDtWalk, fhCalDX0, fhCalDY0, fhCalPos, fhCalPosition, fhCalR0, fhCalTOff, fhCalWalk, fhCalWalkAv, fhCalXYTOff, fTofCalDigiVec, fTofClusterizer, fTofDigiMatchColl, fTofFindTracks, fTrackletTools, CbmHit::GetAddress(), CbmTofDigiPar::GetCell(), CbmTofDigi::GetChannel(), CbmTofAddress::GetChannelId(), CbmTofTracklet::GetFitT(), CbmTofTracklet::GetFitX(), CbmTofTracklet::GetFitY(), CbmLink::GetIndex(), CbmMatch::GetLink(), CbmTofTracklet::GetNofHits(), CbmMatch::GetNofLinks(), CbmTofFindTracks::GetNReqStations(), CbmTofTracklet::GetR0(), CbmTofDigi::GetRpc(), CbmTofAddress::GetRpcId(), CbmTofDigi::GetSide(), CbmTofDigiBdfPar::GetSigVel(), CbmTofDigi::GetSm(), CbmTofAddress::GetSmId(), CbmTofAddress::GetSmType(), CbmTofTrackletTools::GetTexpected(), CbmHit::GetTime(), CbmTofDigi::GetTime(), CbmTofFindTracks::GetTOff(), CbmTofFindTracks::GetTofHitIndex(), CbmTofTracklet::GetTofHitIndex(), CbmTofTracklet::GetTofHitPointer(), CbmTofDigi::GetTot(), CbmTofTracklet::GetTt(), CbmTofFindTracks::GetTtLight(), CbmTofDigi::GetType(), CbmTofAddress::GetUniqueAddress(), CbmPixelHit::GetX(), CbmPixelHit::GetY(), CbmHit::GetZ(), CbmTofEventClusterizer::MasterToLocal(), NevtT, and size().
void CbmTofCalibrator::FillHitCalHist | ( | CbmTofHit * | pHit, |
Int_t | iOpt, | ||
CbmEvent * | pEvent = NULL, | ||
TClonesArray * | tHitColl = NULL ) |
Definition at line 504 of file CbmTofCalibrator.cxx.
References cLight, DetMask, CbmTofHit::Dist3D(), fDetIdIndexMap, fDigiBdfPar, fhCalCluSize, fhCalCluTrms, fhCalDelPos, fhCalDelTOff, fhCalDtWalk, fhCalPos, fhCalPosition, fhCalTOff, fhCalTofOff, fhCalTot, fhCalTotYTOff, fhCalTotYWalk, fhCalWalk, fhCalXYTOff, fhCalXYTot, fTofCalDigiVec, fTofClusterizer, CbmHit::GetAddress(), CbmTofDigi::GetAddress(), CbmTofEventClusterizer::GetBeamAddr(), CbmTofDigi::GetChannel(), CbmTofAddress::GetChannelId(), CbmTofEventClusterizer::GetCluSizeMin(), CbmEvent::GetIndex(), CbmLink::GetIndex(), CbmMatch::GetLink(), CbmTofEventClusterizer::GetLocalY(), CbmTofEventClusterizer::GetMatchIndexPointer(), CbmTofDigiBdfPar::GetNbChan(), CbmEvent::GetNofData(), CbmMatch::GetNofLinks(), CbmTofHit::GetR(), CbmTofDigi::GetRpc(), CbmTofAddress::GetRpcId(), CbmTofDigi::GetSide(), CbmTofDigiBdfPar::GetSigVel(), CbmTofDigi::GetSm(), CbmTofAddress::GetSmId(), CbmTofAddress::GetSmType(), CbmHit::GetTime(), CbmTofDigi::GetTime(), CbmTofDigi::GetTot(), CbmTofDigi::GetType(), CbmPixelHit::GetX(), CbmPixelHit::GetY(), CbmHit::GetZ(), kTofHit, CbmTofEventClusterizer::MasterToLocal(), NevtH, pRef, and size().
Referenced by CbmTofEventClusterizer::Exec().
double * CbmTofCalibrator::find_tofedge | ( | const char * | hname | ) |
Definition at line 2241 of file CbmTofCalibrator.cxx.
References find_tofedge().
double * CbmTofCalibrator::find_tofedge | ( | const char * | hname, |
Double_t | dThr, | ||
Double_t | dLen ) |
Referenced by find_tofedge(), and UpdateCalHist().
double * CbmTofCalibrator::fit_tofedge | ( | const char * | hname | ) |
Definition at line 2369 of file CbmTofCalibrator.cxx.
References fit_tofedge(), fTofClusterizer, and CbmTofEventClusterizer::GetEdgeThr().
double * CbmTofCalibrator::fit_tofedge | ( | const char * | hname, |
Double_t | dTmax, | ||
Double_t | dThr ) |
Definition at line 2274 of file CbmTofCalibrator.cxx.
References f1_tedge().
Referenced by fit_tofedge(), and UpdateCalHist().
void CbmTofCalibrator::HstDoublets | ( | CbmTofTracklet * | pTrk | ) |
Definition at line 2107 of file CbmTofCalibrator.cxx.
References CbmTofTracklet::Dist3D(), fDetIdIndexMap, fhDoubletDd, fhDoubletDt, fhDoubletV, CbmTofTracklet::GetNofHits(), CbmHit::GetTime(), CbmTofTracklet::GetTofDetIndex(), CbmTofTracklet::GetTofHitPointer(), and CbmHit::GetZ().
InitStatus CbmTofCalibrator::Init | ( | ) |
Definition at line 95 of file CbmTofCalibrator.cxx.
References cBadChannelFile, CreateCalHist(), fDigiMan, fEvtHeader, fTofCalDigiVec, fTofClusterizer, fTofDigiMatchColl, fTofFindTracks, fTofId, fTrackletTools, CbmTofEventClusterizer::GetCalParFileName(), CbmDigiManager::Init(), InitParameters(), CbmDigiManager::Instance(), CbmTofEventClusterizer::Instance(), CbmTofFindTracks::Instance(), CbmDigiManager::IsPresent(), and kTof.
Referenced by CbmTofEventClusterizer::Init(), and CbmTofFindTracks::Init().
Bool_t CbmTofCalibrator::InitParameters | ( | ) |
Definition at line 172 of file CbmTofCalibrator.cxx.
References fDigiBdfPar, and fDigiPar.
Referenced by Init().
|
privatedelete |
void CbmTofCalibrator::ReadHist | ( | TFile * | fhFile | ) |
Definition at line 1974 of file CbmTofCalibrator.cxx.
References fDigiBdfPar, fhCalWalk, fhCorPos, fhCorSvel, fhCorTOff, fhCorTot, fhCorTotOff, fhCorWalk, fHist, fTofClusterizer, CbmTofDigiBdfPar::GetDetUId(), CbmTofDigiBdfPar::GetNbChan(), CbmTofDigiBdfPar::GetNbDet(), CbmTofDigiBdfPar::GetNbRpc(), CbmTofDigiBdfPar::GetNbSm(), CbmTofDigiBdfPar::GetNbSmTypes(), CbmTofAddress::GetRpcId(), CbmTofAddress::GetSmId(), CbmTofAddress::GetSmType(), CbmTofEventClusterizer::GetTotMax(), CbmTofEventClusterizer::GetTotMin(), hSvel, and nbClWalkBinX.
Referenced by UpdateCalHist().
|
inline |
Definition at line 79 of file CbmTofCalibrator.h.
References fbBeam.
Referenced by CbmTofFindTracks::Init().
|
inline |
Definition at line 78 of file CbmTofCalibrator.h.
References fdR0Lim.
Referenced by CbmTofFindTracks::Init().
double CbmTofCalibrator::TruncatedMeanY | ( | TH2 * | pHst, |
double | RmsLim = 1. ) |
Definition at line 2375 of file CbmTofCalibrator.cxx.
Referenced by UpdateCalHist().
Bool_t CbmTofCalibrator::UpdateCalHist | ( | Int_t | iOpt | ) |
Save old global file and folder pointer to avoid messing with FairRoot
Restore old global file and folder pointer to avoid messing with FairRoot
Definition at line 982 of file CbmTofCalibrator.cxx.
References CalcChi2(), cBadChannelFile, dTmax, dValidEdge, fDigiBdfPar, fDigiPar, fhCalChannelDt, fhCalChannelDy, fhCalCounterDt, fhCalDelPos, fhCalDelTOff, fhCalPos, fhCalPosition, fhCalTOff, fhCalTofOff, fhCalTot, fhCalWalk, fhCalWalkAv, fhCorPos, fhCorTOff, fhCorTot, fhCorWalk, find_tofedge(), CbmTofEventClusterizer::find_yedges(), fit_tofedge(), CbmTofEventClusterizer::fit_ybox(), fTofClusterizer, fTofId, CbmTofEventClusterizer::GetCalParFileName(), CbmTofDigiPar::GetCell(), CbmTofDigiBdfPar::GetDetUId(), CbmTofEventClusterizer::GetEdgeFrange(), CbmTofEventClusterizer::GetEdgeLen(), CbmTofEventClusterizer::GetEdgeTbias(), CbmTofEventClusterizer::GetEdgeThr(), CbmTofEventClusterizer::GetModifySigvel(), CbmTofDigiBdfPar::GetNbChan(), CbmTofDigiBdfPar::GetNbDet(), CbmTofDigiBdfPar::GetNbRpc(), CbmTofAddress::GetRpcId(), CbmTofDigiBdfPar::GetSigVel(), CbmTofCell::GetSizey(), CbmTofAddress::GetSmId(), CbmTofAddress::GetSmType(), CbmTofEventClusterizer::GetTotMean(), CbmTofAddress::GetUniqueAddress(), hSvel, kTof, MaxShift, ReadHist(), CbmTofDetectorId::SetDetectorInfo(), TruncatedMeanY(), and WriteHist().
Referenced by CbmTofEventClusterizer::Finish(), and CbmTofFindTracks::Finish().
void CbmTofCalibrator::WriteHist | ( | TFile * | fhFile | ) |
Definition at line 2071 of file CbmTofCalibrator.cxx.
References fDigiBdfPar, fhCorPos, fhCorTOff, fhCorTot, fhCorTotOff, fhCorWalk, fHist, CbmTofDigiBdfPar::GetNbDet(), CbmTofDigiBdfPar::GetNbSmTypes(), hSvel, and size().
Referenced by UpdateCalHist().
|
private |
Definition at line 136 of file CbmTofCalibrator.h.
Referenced by FillCalHist(), and SetBeam().
|
private |
Definition at line 130 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), FillCalHist(), FillHitCalHist(), and HstDoublets().
|
private |
Definition at line 90 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), FillCalHist(), FillHitCalHist(), InitParameters(), ReadHist(), UpdateCalHist(), and WriteHist().
|
private |
Definition at line 82 of file CbmTofCalibrator.h.
Referenced by Init().
|
private |
Definition at line 89 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), FillCalHist(), InitParameters(), and UpdateCalHist().
|
private |
Definition at line 135 of file CbmTofCalibrator.h.
Referenced by FillCalHist(), and SetR0Lim().
|
private |
Definition at line 95 of file CbmTofCalibrator.h.
Referenced by Init().
|
private |
Definition at line 91 of file CbmTofCalibrator.h.
|
private |
Definition at line 103 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), and UpdateCalHist().
|
private |
Definition at line 104 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), and UpdateCalHist().
|
private |
Definition at line 114 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), and FillHitCalHist().
|
private |
Definition at line 113 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), and FillHitCalHist().
|
private |
Definition at line 101 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), and UpdateCalHist().
|
private |
Definition at line 102 of file CbmTofCalibrator.h.
Referenced by CreateCalHist().
|
private |
Definition at line 111 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillHitCalHist(), and UpdateCalHist().
|
private |
Definition at line 112 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillHitCalHist(), and UpdateCalHist().
|
private |
Definition at line 117 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), and FillHitCalHist().
|
private |
Definition at line 98 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), and FillCalHist().
|
private |
Definition at line 99 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), and FillCalHist().
|
private |
Definition at line 108 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), FillHitCalHist(), and UpdateCalHist().
|
private |
Definition at line 107 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), FillCalHist(), FillHitCalHist(), and UpdateCalHist().
|
private |
Definition at line 97 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), and FillCalHist().
|
private |
Definition at line 109 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), FillCalHist(), FillHitCalHist(), and UpdateCalHist().
|
private |
Definition at line 110 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), FillHitCalHist(), and UpdateCalHist().
|
private |
Definition at line 106 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), FillHitCalHist(), and UpdateCalHist().
|
private |
Definition at line 121 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), and FillHitCalHist().
|
private |
Definition at line 120 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), and FillHitCalHist().
|
private |
Definition at line 116 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), FillHitCalHist(), ReadHist(), and UpdateCalHist().
|
private |
Definition at line 115 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), and UpdateCalHist().
|
private |
Definition at line 118 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), FillCalHist(), FillCalHist(), and FillHitCalHist().
|
private |
Definition at line 119 of file CbmTofCalibrator.h.
Referenced by CreateCalHist(), and FillHitCalHist().
|
private |
Definition at line 123 of file CbmTofCalibrator.h.
Referenced by ReadHist(), UpdateCalHist(), and WriteHist().
|
private |
Definition at line 127 of file CbmTofCalibrator.h.
Referenced by ReadHist().
|
private |
Definition at line 124 of file CbmTofCalibrator.h.
Referenced by ReadHist(), UpdateCalHist(), and WriteHist().
|
private |
Definition at line 125 of file CbmTofCalibrator.h.
Referenced by ReadHist(), UpdateCalHist(), and WriteHist().
|
private |
Definition at line 126 of file CbmTofCalibrator.h.
Referenced by ReadHist(), and WriteHist().
|
private |
Definition at line 128 of file CbmTofCalibrator.h.
Referenced by ReadHist(), UpdateCalHist(), and WriteHist().
|
private |
Definition at line 132 of file CbmTofCalibrator.h.
Referenced by HstDoublets().
|
private |
Definition at line 131 of file CbmTofCalibrator.h.
Referenced by HstDoublets().
|
private |
Definition at line 133 of file CbmTofCalibrator.h.
Referenced by HstDoublets().
|
private |
Definition at line 87 of file CbmTofCalibrator.h.
Referenced by FillCalHist(), FillCalHist(), FillHitCalHist(), and Init().
|
private |
Definition at line 83 of file CbmTofCalibrator.h.
Referenced by FillCalHist(), FillCalHist(), FillHitCalHist(), fit_tofedge(), Init(), ReadHist(), and UpdateCalHist().
|
private |
Definition at line 93 of file CbmTofCalibrator.h.
Referenced by FillCalHist(), and Init().
|
private |
Definition at line 84 of file CbmTofCalibrator.h.
Referenced by FillCalHist(), FillCalHist(), and Init().
|
private |
Definition at line 92 of file CbmTofCalibrator.h.
Referenced by Init(), and UpdateCalHist().
|
private |
Definition at line 85 of file CbmTofCalibrator.h.
Referenced by FillCalHist(), and Init().