]>
Commit | Line | Data |
---|---|---|
b62e2a95 | 1 | #if !defined(__CINT__) |
2e9f335b | 2 | |
3 | #include "AliTPCDDLRawData.h" | |
4 | #include "AliTPCCompression.h" | |
2e9f335b | 5 | #endif |
6 | ||
7 | ||
8 | void AliTPCDDLRawData(Int_t LDCsNumber=12){ | |
9 | AliTPCDDLRawData *util=new AliTPCDDLRawData(); | |
10 | AliTPCCompression *u=new AliTPCCompression(); | |
11 | TStopwatch timer; | |
c9bd9d3d | 12 | Int_t eventNumber=0; |
2e9f335b | 13 | static const Int_t NumTable=5; |
c9bd9d3d | 14 | |
15 | util->SetVerbose(1); | |
16 | u->SetVerbose(1); | |
2e9f335b | 17 | |
2e9f335b | 18 | //The Altro File "AltroFormatDDL.dat" is built from "AliTPCDDL.dat" |
19 | util->RawDataAltro(); | |
c9bd9d3d | 20 | |
21 | /* | |
2e9f335b | 22 | //The file "AltroFormatDDL.dat" is converted in a txt file "AltroFormatDDL.txt" |
23 | //that is used for debugging | |
24 | u->ReadAltroFormat("AltroFormatDDL.txt","AltroFormatDDL.dat"); | |
c9bd9d3d | 25 | */ |
26 | ||
27 | /* | |
28 | //TABLES CREATION | |
2e9f335b | 29 | //Tables are created and stored in as sequence of binary files |
30 | u->CreateTables("AltroFormatDDL.dat",NumTable); | |
c9bd9d3d | 31 | */ |
32 | ||
33 | ||
34 | cout<<"Insert the event number:"; | |
35 | cin>>eventNumber; | |
36 | cout<<endl; | |
2e9f335b | 37 | |
2e9f335b | 38 | //SLICE CREATION |
39 | //Slices are built here | |
40 | timer.Start(); | |
c9bd9d3d | 41 | util->RawData(LDCsNumber,eventNumber); |
2e9f335b | 42 | timer.Stop(); |
43 | timer.Print(); | |
c9bd9d3d | 44 | |
45 | /* | |
2e9f335b | 46 | //SLICE CHECKING |
47 | //An Altro File is created from the slides | |
a79660fb | 48 | cout<<"slice control"<<endl; |
c9bd9d3d | 49 | util->RawDataAltroDecode(LDCsNumber,eventNumber,0); |
2e9f335b | 50 | ///The Altro file AltroDDLRecomposed.dat is converted in a txt file AltroDDLRecomposed.txt |
51 | //This file must be equal to the ones created above. | |
52 | u->ReadAltroFormat("AltroDDLRecomposed.txt","AltroDDLRecomposed.dat"); | |
c9bd9d3d | 53 | */ |
b62e2a95 | 54 | |
c9bd9d3d | 55 | |
2e9f335b | 56 | //SLICE COMPRESSION |
a79660fb | 57 | cout<<"Slice Compression"<<endl; |
58 | //Slices are compressed here using the tables created above or an optimized set of tables | |
59 | //(Tables file for Huffman coding are required) | |
2e9f335b | 60 | timer.Start(); |
c9bd9d3d | 61 | util->RawDataCompDecompress(LDCsNumber,eventNumber,0); |
2e9f335b | 62 | timer.Stop(); |
63 | timer.Print(); | |
c9bd9d3d | 64 | |
65 | /* | |
2e9f335b | 66 | //SLICE DECOMPRESSION |
67 | timer.Start(); | |
c9bd9d3d | 68 | util->RawDataCompDecompress(LDCsNumber,eventNumber,1); |
2e9f335b | 69 | timer.Stop(); |
70 | timer.Print(); | |
c9bd9d3d | 71 | */ |
9f992f70 | 72 | |
c9bd9d3d | 73 | /* |
2e9f335b | 74 | //SLICE DECOMPRESSED CHECKING |
75 | //A new Altro file is created from the decompressed slides | |
c9bd9d3d | 76 | util->RawDataAltroDecode(LDCsNumber,eventNumber,1); |
2e9f335b | 77 | //Convertion of the Altro file AltroDDLRecomposedDec.dat in a txt file AltroDDLRecomposedDec.txt |
78 | //Useful for debugging | |
79 | u->ReadAltroFormat("AltroDDLRecomposedDec.txt","AltroDDLRecomposedDec.dat"); | |
c9bd9d3d | 80 | */ |
2e9f335b | 81 | delete util; |
82 | delete u; | |
83 | return; | |
84 | } |