Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 0 additions & 53 deletions offline/framework/ffarawmodules/CemcCheck.cc

This file was deleted.

32 changes: 0 additions & 32 deletions offline/framework/ffarawmodules/CemcCheck.h

This file was deleted.

125 changes: 0 additions & 125 deletions offline/framework/ffarawmodules/ClockDiffCheck.cc
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
#include <fun4all/SubsysReco.h> // for SubsysReco

#include <ffarawobjects/CaloPacket.h>
#include <ffarawobjects/CaloPacketContainer.h>

#include <phool/PHCompositeNode.h>
#include <phool/PHDataNode.h>
Expand Down Expand Up @@ -98,20 +97,6 @@ int ClockDiffCheck::process_event(PHCompositeNode *topNode)
FillPacketDiff(pkt);
}

std::vector<std::string> nodenames{"CEMCPackets", "HCALPackets", "MBDPackets", "SEPDPackets", "ZDCPackets"};
for (const auto &iter : nodenames)
{
CaloPacketContainer *cemccont = findNode::getClass<CaloPacketContainer>(topNode, iter);
if (!cemccont)
{
// std::cout << "ClockDiffCheck: " << "could not find " << iter << " node" << std::endl;
}
else
{
FillCaloClockDiff(cemccont);
}
}

for (const auto &iter : m_PacketNodeNames)
{
if (iter == "14001")
Expand Down Expand Up @@ -195,107 +180,6 @@ int ClockDiffCheck::process_event(PHCompositeNode *topNode)
}
}

for (const auto &nodeiter : nodenames)
{
CaloPacketContainer *container = findNode::getClass<CaloPacketContainer>(topNode, nodeiter);
if (!container)
{
continue;
}
if (delBadPkts)
{
for (unsigned int i = 0; i < container->get_npackets(); i++)
{
unsigned int packetID = container->getPacket(i)->getIdentifier();
for (unsigned int badPacket : badPackets)
{
if (badPacket == packetID)
{
if (Verbosity() > 1)
{
std::cout << "ClockDiffCheck: " << "Dropping packet " << container->getPacket(i)->getIdentifier() << " for XMIT clock mismatch" << std::endl;
}
container->deletePacket(container->getPacket(i));
break;
}
}
}
}

std::vector<std::vector<int>> EvtCounts;
std::vector<int> NrAndCount(2);
NrAndCount[1] = 1;
int counter = 0;
int bestEvt = -1;
int bestEvtCnt = 0;
unsigned int npacket = container->get_npackets();
for (unsigned int i = 0; i < npacket; i++)
{
CaloPacket *packet = container->getPacket(i);
if (packet)
{
int nrModules = packet->iValue(0, "NRMODULES");
for (int j = 0; j < nrModules; j++)
{
int k;
for (k = 0; k < counter; k++)
{
if (EvtCounts[k][0] == packet->iValue(j, "FEMEVTNR"))
{
EvtCounts[k][1]++;
break;
}
}
if (k >= counter)
{
NrAndCount[0] = packet->iValue(j, "FEMEVTNR");
EvtCounts.push_back(NrAndCount);
counter++;
}
}
}
}
if (counter > 1)
{
for (int i = 0; i < counter; i++)
{
if (bestEvtCnt < EvtCounts[i][1])
{
bestEvtCnt = EvtCounts[i][1];
bestEvt = EvtCounts[i][0];
}
}
for (unsigned int i = 0; i < npacket; ++i)
{
CaloPacket *packet = container->getPacket(i);
if (packet)
{
for (int j = 0; j < packet->iValue(0, "NRMODULES"); j++)
{
if (packet->iValue(j, "FEMEVTNR") != bestEvt && bestEvt != -1)
{
static int icnt = 0;
if (icnt < 1000)
{
std::cout << "ClockDiffCheck: " << "found different FEM clock for packet " << packet->getIdentifier() << std::endl;
icnt++;
}
if (delBadPkts)
{
if (Verbosity() > 1)
{
std::cout << "ClockDiffCheck: " << "deleting packet " << packet->getIdentifier()
<< " with fem clock mismatch" << std::endl;
}
container->deletePacket(packet);
}
break;
}
}
}
}
}
}
for (const auto &iter : m_PacketNodeNames)
{
CaloPacket *calopacket = findNode::getClass<CaloPacket>(topNode, iter);
Expand Down Expand Up @@ -338,15 +222,6 @@ int ClockDiffCheck::process_event(PHCompositeNode *topNode)
return Fun4AllReturnCodes::EVENT_OK;
}

void ClockDiffCheck::FillCaloClockDiff(CaloPacketContainer *pktcont)
{
for (unsigned int i = 0; i < pktcont->get_npackets(); i++)
{
FillCaloClockDiffSngl(pktcont->getPacket(i));
}
return;
}

void ClockDiffCheck::FillCaloClockDiffSngl(CaloPacket *calopkt)
{
unsigned int packetid = calopkt->getIdentifier();
Expand Down
2 changes: 0 additions & 2 deletions offline/framework/ffarawmodules/ClockDiffCheck.h
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
#include <vector>

class CaloPacket;
class CaloPacketContainer;
class Fun4AllInputManager;
class PHCompositeNode;
class TH1;
Expand All @@ -30,7 +29,6 @@ class ClockDiffCheck : public SubsysReco, public DumpPacket

int End(PHCompositeNode *topNode) override;

void FillCaloClockDiff(CaloPacketContainer *pktcont);
void FillCaloClockDiffSngl(CaloPacket *calopkt);
void FillPacketDiff(OfflinePacket *pkt);

Expand Down
53 changes: 0 additions & 53 deletions offline/framework/ffarawmodules/HcalCheck.cc

This file was deleted.

32 changes: 0 additions & 32 deletions offline/framework/ffarawmodules/HcalCheck.h

This file was deleted.

14 changes: 2 additions & 12 deletions offline/framework/ffarawmodules/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -12,48 +12,38 @@ AM_LDFLAGS = \

pkginclude_HEADERS = \
BcoRangeCheck.h \
CemcCheck.h \
ClockDiffCheck.h \
DumpPacket.h \
EventCombiner.h \
EventNumberCheck.h \
Gl1BcoDump.h \
Gl1Check.h \
HcalCheck.h \
InttCheck.h \
InttBcoDump.h \
InttGl1Check.h \
LL1Check.h \
MbdCheck.h \
StreamingCheck.h \
SEpdCheck.h \
TpcBcoDump.h \
TpcCheck.h \
ZdcCheck.h
TpcCheck.h

lib_LTLIBRARIES = \
libffarawmodules.la

libffarawmodules_la_SOURCES = \
BcoRangeCheck.cc \
CemcCheck.cc \
ClockDiffCheck.cc \
DumpPacket.cc \
EventCombiner.cc \
EventNumberCheck.cc \
Gl1BcoDump.cc \
Gl1Check.cc \
HcalCheck.cc \
InttBcoDump.cc \
InttCheck.cc \
InttGl1Check.cc \
LL1Check.cc \
MbdCheck.cc \
SEpdCheck.cc \
StreamingCheck.cc \
TpcBcoDump.cc \
TpcCheck.cc \
ZdcCheck.cc
TpcCheck.cc

libffarawmodules_la_LIBADD = \
-lEvent \
Expand Down
Loading
Loading