CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Classes | Functions | Variables
ztail Namespace Reference

Classes

class  Decoder
 

Functions

def strip_gzip_header
 

Variables

tuple args = parser.parse_args()
 
string BLOCK_MAGIC = "\x00\x00\xFF\xFF"
 
tuple d = Decoder(args.file, args.n)
 
int DECOMPRESS_BUF_SIZE = 4
 
string ENDLINE_MAGIC = "\n"
 
tuple parser = argparse.ArgumentParser(description='tail, but for gzip files (with Z_FULL_SYNC)')
 

Function Documentation

def ztail.strip_gzip_header (   body)

Definition at line 16 of file ztail.py.

Referenced by ztail.Decoder.decode().

16 
17 def strip_gzip_header(body):
18  assert body[0:2] == "\x1f\x8b"
19  method, flags, mtime = struct.unpack("<BBIxx", body[2:10])
20 
21  FHCRC = 0x02
22  FEXTRA = 0x04
23  FNAME = 0x08
24  FCOMMENT = 0x10
25 
26  i = 10
27 
28  if flags & FEXTRA:
29  size, = struct.unpack("<H", body[i:i+2])
30  i += size + 2
31 
32  def skip_until_zero(ix):
33  while body[ix] != '\x00': ix += 1
34  return ix + 1
35 
36  if flags & FNAME: i = skip_until_zero(i)
37  if flags & FCOMMENT: i = skip_until_zero(i)
38  if flags & FHCRC: i += 2
39 
40  body = body[i:]
41  return body
def strip_gzip_header
Definition: ztail.py:16

Variable Documentation

tuple ztail.args = parser.parse_args()

Definition at line 149 of file ztail.py.

string ztail.BLOCK_MAGIC = "\x00\x00\xFF\xFF"

Definition at line 11 of file ztail.py.

tuple ztail.d = Decoder(args.file, args.n)

Definition at line 151 of file ztail.py.

Referenced by GenParticleDecaySelector.add(), pat::PATUserDataHelper< ObjectType >.add(), FWCaloDataHistProxyBuilder.addEntryToTEveCaloData(), GEMSimTrackMatch.analyze(), HcalSummaryClient.analyze(), GEMDigiTrackMatch.analyze(), GEMRecHitTrackMatch.analyze(), L1TScalersSCAL.analyze(), ElectronMcSignalValidator.analyze(), RawToText.analyze(), HLTMCtruth.analyze(), HcalRawDataMonitor.analyze(), ElectronMcFakeValidator.analyze(), EcalTPGAnalyzer.analyze(), EcalTrigPrimAnalyzer.analyze(), GsfElectronDataAnalyzer.analyze(), GsfElectronMCFakeAnalyzer.analyze(), GsfElectronFakeAnalyzer.analyze(), GsfElectronMCAnalyzer.analyze(), MCEfficiencyAnalyzer.analyze(), TPGCheck.analyze(), edm::TestMixedSource.analyze(), TestPythiaDecays.analyze(), LhcTrackAnalyzer.analyze(), ErsatzMEt.analyze(), SiStripSpyDisplayModule.analyze(), tauImpactParameter::LagrangeMultipliersFitter.applyLagrangianConstraints(), fastmath.atan2r(), GctRawToDigi.autoDetectRequiredFormatTranslator(), BestTracks(), edm.binary_search_all(), GctFormatTranslateMCLegacy.blockToAllRctCaloRegions(), GctFormatTranslateV35.blockToFibres(), GctFormatTranslateV38.blockToFibres(), GctFormatTranslateMCLegacy.blockToFibres(), GctFormatTranslateV35.blockToGctEmCandsAndEnergySums(), GctFormatTranslateV38.blockToGctEmCandsAndEnergySums(), GctFormatTranslateMCLegacy.blockToGctEmCandsAndEnergySums(), GctFormatTranslateV35.blockToGctInternEmCand(), GctFormatTranslateV38.blockToGctInternEmCand(), GctFormatTranslateV35.blockToGctInternEtSums(), GctFormatTranslateV38.blockToGctInternEtSums(), GctFormatTranslateV35.blockToGctInternEtSumsAndJetCluster(), GctFormatTranslateV38.blockToGctInternEtSumsAndJetCluster(), GctFormatTranslateV38.blockToGctInternHtMissPostWheel(), GctFormatTranslateV38.blockToGctInternHtMissPreWheel(), GctFormatTranslateV35.blockToGctInternRingSums(), GctFormatTranslateV38.blockToGctInternRingSums(), GctFormatTranslateV35.blockToGctJetCandsAndCounts(), GctFormatTranslateV38.blockToGctJetCandsAndCounts(), GctFormatTranslateMCLegacy.blockToGctJetCandsAndCounts(), GctFormatTranslateV35.blockToGctJetClusterMinimal(), GctFormatTranslateV38.blockToGctJetClusterMinimal(), GctFormatTranslateV35.blockToGctJetPreCluster(), GctFormatTranslateV38.blockToGctJetPreCluster(), GctFormatTranslateV35.blockToGctTrigObjects(), GctFormatTranslateV38.blockToGctTrigObjects(), GctFormatTranslateV35.blockToGctWheelInputInternEtAndRingSums(), GctFormatTranslateV38.blockToGctWheelInputInternEtAndRingSums(), GctFormatTranslateV35.blockToGctWheelOutputInternEtAndRingSums(), GctFormatTranslateV38.blockToGctWheelOutputInternEtAndRingSums(), GctFormatTranslateV35.blockToRctCaloRegions(), GctFormatTranslateV38.blockToRctCaloRegions(), GctFormatTranslateV35.blockToRctEmCand(), GctFormatTranslateV38.blockToRctEmCand(), GctFormatTranslateMCLegacy.blockToRctEmCand(), GEMPadDigiProducer.buildPads(), TFitParticleSpher.calc4Vec(), TFitParticleESpher.calc4Vec(), HLTBTagHarvestingAnalyzer.calculateEfficiency1D(), edm::PileUp.CalculatePileup(), HcalCoarsePedestalClient.calculateProblems(), HcalDetDiagLaserClient.calculateProblems(), HcalDeadCellClient.calculateProblems(), HcalDetDiagNoiseMonitorClient.calculateProblems(), HcalDetDiagPedestalClient.calculateProblems(), HcalDetDiagTimingClient.calculateProblems(), HcalDigiClient.calculateProblems(), HcalHotCellClient.calculateProblems(), HcalNZSClient.calculateProblems(), HcalTrigPrimClient.calculateProblems(), HcalBeamClient.calculateProblems(), HcalRecHitClient.calculateProblems(), HcalRawDataClient.calculateProblems(), condbon.cdbon_read_rec(), edm::PrintEventSetupDataRetrieval.check(), SiStripAPVRestorer.CheckBaseline(), FFTJetProducer.checkConvergence(), FWGeometryTableManager.checkHierarchy(), FWGeometryTableManager.checkRegionOfInterest(), TtDecayChannelSelector.checkSum(), tauImpactParameter::LagrangeMultipliersFitter.chiSquare(), RPCEventSummary.clientOperation(), closestJet(), funct::Difference< FractionStruct< a, b >, FractionStruct< c, d > >.combine(), MultipleScatteringUpdator.compute(), pftools::Calibratable.computeMean(), DTDigitizer.computeTime(), convert32(), convert64(), npstat.convolutionHistoMap(), GEMDigiMatcher.coPadNumbersInDetId(), d2str(), edm::service.d2str(), CSCCLCTData.dataWord(), reco::CompositeCandidate.daughter(), AntiElectronIDMVA5.dCrackEta(), AntiElectronIDMVA6.dCrackEta(), ParticleDecayDrawer.decay(), EcalDumpRaw.decode(), EnergyResolutionVsLumi.Decomposition(), edm::reftobase::RefVectorHolder< REFV >::const_iterator_imp_specific.decrease(), edm::reftobase::IndirectVectorHolder< T >::const_iterator_imp_specific.decrease(), edm::reftobase::VectorHolder< T, REFVECTOR >::const_iterator_imp_specific.decrease(), Deltas(), npstat.densityScanHistoMap(), HistoryBase.depth(), PhysicsTools::Spline::Segment.deriv(), ME0SegFit.derivativeMatrix(), GEMCSCSegFit.derivativeMatrix(), edm::service::MessageServicePSetValidation.destinationPSets(), ClusterProducerFP420.difNarr(), ClusterProducerFP420.difWide(), matching.digi_bx(), matching.digi_channel(), matching.digi_dphi(), matching.digi_id(), matching.digi_pattern(), matching.digi_quality(), matching.digi_type(), FWEveDigitSetScalableMarkerGL.DirectDraw(), RPCCompDetId.disk(), JetCoreClusterSplitter.distScore(), reco::PFDisplacedVertexCandidate.distVector(), DDEcalPreshowerAlgo.doLadders(), FWLiteJobMetadataManager.doUpdate(), FWFFMetadataManager.doUpdate(), GeneralHLTOffline.dqmBeginRun(), RPCEfficiencySecond.dqmEndJob(), RPCEfficiencyShiftHisto.dqmEndJob(), DTConfigLUTs.DTConfigLUTs(), edmNew::DetSetVector< T >::FastFiller.dummy(), edmNew::DetSetVector< T >::TSFastFiller.dummy(), hcaldqm::ContainerCompact.dump(), DTTrigGeom.dumpLUT(), DTConfigManager.dumpLUTParam(), GlobalTrackerMuonAlignment.endJob(), HcalRawDataMonitor.endLuminosityBlock(), KalmanVertexTrackCompatibilityEstimator< N >.estimate(), pftools::Exercises3.evaluateSpaceManager(), CalibratableTest.extractCandidate(), F(), EcalCondDBInterface.fetchFEDelaysForRun(), CandCommonVertexFitterBase.fill(), PFCandCommonVertexFitterBase.fill(), CandKinematicVertexFitter.fill(), HcalCoarsePedestalMonitor.fill_Nevents(), HcalDigiMonitor.fill_Nevents(), ME0DigiPreRecoModel.fillDigis(), GEMDigiModel.fillDigis(), HcalObjRepresent.fillOneGain(), HcalObjRepresent::ADataRepr.fillOneGain(), RunDCSHVDat.fillTheMapByTime(), HcalObjRepresent.FillUnphysicalHEHFBins(), FillUnphysicalHEHFBins(), Filter.Filter(), HLTHcalMETNoiseCleaner.filter(), HLTHcalMETNoiseFilter.filter(), HSCPHLTFilter.filter(), edm.find_in_all(), gen::EvtGenInterface.findLastinChain(), MSLayersAtAngle.findLayer(), CSCValidation.findNonAssociatedRecHits(), SETFilter.findParabolaMinimum(), LinearFit.fit(), hitfit::Chisq_Constrainer.fit(), ME0SegFit.fitlsq(), GEMCSCSegFit.fitlsq(), L1GctInternHFData.fromConcBitCounts(), L1GctInternHFData.fromConcRingSums(), L1GctInternJetData.fromEmulator(), L1GctInternJetData.fromGctTrigObject(), L1GctInternJetData.fromJetCluster(), L1GctInternJetData.fromJetClusterMinimal(), L1GctInternJetData.fromJetPreCluster(), L1GctInternHFData.fromWheelBitCounts(), L1GctInternHFData.fromWheelRingSums(), npstat::ArrayND< Numeric, StackLen, StackDim >.functorFillLoop(), edm::service::MessageServicePSetValidation.fwkJobReportPSets(), GammaContinuedFraction(), GSUtilities.gauss(), PairProductionSimulator.gbteth(), BremsstrahlungSimulator.gbteth(), gen::Hydjet2Hadronizer.generatePartonsAndHadronize(), CSCMonitorObject.GetBinContent(), CSCMonitorObject.GetBinError(), l1t::MP7BufferDumpToRaw.getBlocks(), SimG4HcalHitJetFinder.getClusters(), ConversionFinder.getConversionInfo(), LMFCorrCoefDat.getCorrections(), HLTConfigProvider.getDataFrom(), TFitParticleSpher.getDerivative(), HCALResponse.getDet(), ZdcSD.getEnergyDeposit(), CastorSD.getEnergyDeposit(), CSCMonitorObject.GetEntries(), BasicHepMCValidation::ParticleMonitor.GetFinal(), HLTTauMCProducer.getGenDecayProducts(), GflashTrajectory.getL2DAtR(), popcon::EcalLaserHandler.getNewObjects(), LMFIOV.getParameters(), pftools::ParticleDeposit.getRecEnergy(), DataReducer< T >.getReducedDataList(), TrackAssociatorByPositionImpl.getState(), pftools::ParticleDeposit.getTruthEnergy(), GlobalTrackerMuonAlignment.gradientGlobal(), MonitorXMLParser.handleElement(), ecalpyutils.hashedIndex(), ecalpyutils.hashedIndexEE(), HcalRawDataClient.hashup(), HcalRawDataMonitor.hashup(), HCALResponse.HCALResponse(), HelixBarrelPlaneCrossing2OrderLocal.HelixBarrelPlaneCrossing2OrderLocal(), CSCChamberFitter.hessian(), HcalHF_S9S1algorithm.HFSetFlagFromS9S1(), QualityCutsAnalyzer::histogram_element_t.histogram_element_t(), HcalDetDiagLaserClient.htmlOutput(), HcalDetDiagPedestalClient.htmlOutput(), edm::reftobase::RefVectorHolder< REFV >::const_iterator_imp_specific.increase(), edm::reftobase::IndirectVectorHolder< T >::const_iterator_imp_specific.increase(), edm::reftobase::VectorHolder< T, REFVECTOR >::const_iterator_imp_specific.increase(), FileInPath.init(), CheckHitPattern.init(), PFCheckHitPattern.init(), CandMatcherBase< C1, C2 >.initMaps(), edm::OwnVector< T, P >.insert(), matching.is_valid(), edm.isFinite(), ecalpyutils.ism(), CSCChamberFitter.lhsVector(), edm::service::MessageLoggerDefaults.limit(), npstat::ArrayND< Numeric, StackLen, StackDim >.linearFillLoop(), linearFit(), PixelEndcapLinkMaker.links(), PixelBarrelLinkMaker.links(), cscdqm::Collection.load(), ClusterShapeHitFilter.loadPixelLimits(), Plane.localZclamped(), SiStripApvShotCleaner.loop(), edm.lower_bound_all(), LzmaProps_Decode(), TFileDirectory.make(), ValidateGeometry.makeHistograms(), hcalCalib.makeTextFile(), OutInConversionSeedFinder.makeTrackState(), GEMDigiMatcher.matchDigisToSimTrack(), GEMRecHitMatcher.matchRecHitsToSimTrack(), SimHitMatcher.matchSimHitsToSimTrack(), DDStreamer.materials_read(), npstat::ArrayND< Numeric, StackLen, StackDim >.maxAbsDifference(), mcMuDaughter(), GlobalTrackerMuonAlignment.misalignMuon(), GlobalTrackerMuonAlignment.misalignMuonL(), MLP_MatrixVector(), MLP_MatrixVectorBias(), MuonSimHitNumberingScheme.MuonSimHitNumberingScheme(), MuonSlaveSD.MuonSlaveSD(), RPCNoisyStripTest.myBooker(), RPCClusterSizeTest.myBooker(), RPCMultiplicityTest.myBooker(), RPCOccupancyTest.myBooker(), RPCChamberQuality.myBooker(), DTDBDataHandle.nearestInt(), GEMDigiMatcher.nLayersWithDigisInSuperChamber(), GEMDigiMatcher.nLayersWithPadsInSuperChamber(), oldMUcompute(), TrackClassFilter.operator()(), CandMatcherBase< C1, C2 >.operator()(), ROOT::Math::Transform3DPJ.operator()(), FFTJetCorrectorTransient.operator*=(), reco::candidate::iterator.operator+=(), reco::candidate::const_iterator.operator+=(), Selection< C, Selector, StoreContainer >::const_iterator.operator+=(), edm::OwnArray< T, MAX_SIZE, P >::const_iterator.operator+=(), edm::OwnVector< T, P >::const_iterator.operator+=(), edm::OwnArray< T, MAX_SIZE, P >::iterator.operator+=(), edm::OwnVector< T, P >::iterator.operator+=(), edm::ValueMap< T >::const_iterator.operator+=(), reco::candidate::iterator.operator-=(), reco::candidate::const_iterator.operator-=(), Selection< C, Selector, StoreContainer >::const_iterator.operator-=(), edm::OwnArray< T, MAX_SIZE, P >::const_iterator.operator-=(), edm::OwnVector< T, P >::const_iterator.operator-=(), edm::OwnArray< T, MAX_SIZE, P >::iterator.operator-=(), edm::OwnVector< T, P >::iterator.operator-=(), edm::ValueMap< T >::const_iterator.operator-=(), operator<<(), operator>>(), reco::utilsNew::CandMatcher< C >.operator[](), edm::service::MessageLoggerDefaults.output(), l1t::stage1::RCTEmRegionPacker.pack(), GEMDigiMatcher.padNumbersInDetId(), GrandCanonical.ParticleEnergyDensity(), NAStrangeDensity.ParticleNumberDensity(), GrandCanonical.ParticleNumberDensity(), ParticleReplacerZtautau.ParticleReplacerZtautau(), HelixBarrelPlaneCrossing2OrderLocal.positionOnly(), GctDigiToRaw.print(), pftools::SpaceManager.printCalibrations(), ParticleTreeDrawer.printDecay(), HcalDeadCellMonitor.processEvent(), HLTHcalTowerNoiseCleaner.produce(), HLTHcalTowerNoiseCleanerWithrechit.produce(), GenParticleProducer.produce(), GlobalTrackQualityProducer.produce(), pat::GenPlusSimParticleProducer.produce(), TextToRaw.produce(), MuonSegmentProducer.produce(), PFTau3ProngReco.produce(), SmearedJetProducerT< T >.produce(), PhotonPair.pt(), edm::OwnArray< T, MAX_SIZE, P >.push_back(), edmNew::DetSetVector< T >::FastFiller.push_back(), edmNew::DetSetVector< T >::TSFastFiller.push_back(), TiXmlElement.QueryFloatAttribute(), MuonTimingFiller.rawFit(), l1t::AMC13DumpToRaw.readEvent(), l1t::AMCDumpToRaw.readEvent(), GEMRecHitMatcher.recHitMeanPosition(), VertexFitterManager.registerFitter(), VertexRecoManager.registerReconstructor(), edm::service::MessageLoggerDefaults.reportEvery(), HcalRawDataMonitor.reset(), EtaPhiHists.Reset(), HcalObjRepresent.Reset(), FW3DViewDistanceMeasureTool.resetAction(), HLTriggerJSONMonitoring.resetRun(), TriggerJSONMonitoring.resetRun(), EnergyResolutionVsLumi.Resolution(), BeamHaloPairGenerator.run(), UrbanMscModel93.SampleCosineTheta(), CSCDigiValidator.sanitizeWireDigis(), JetCorretPair.scale(), PFJetCorretPair.scale(), edm.search_all(), JetCoreClusterSplitter.secondDistDiffScore(), JetCoreClusterSplitter.secondDistScore(), FFTJetProducer.selectTreeNodes(), Booster.set(), AddFourMomenta.set(), edm::OwnVector< T, P >.set(), EtaPhiHists.setBinLabels(), ME0SegFit.setChi2(), GEMCSCSegFit.setChi2(), hcalCalib.SetConeMaxDist(), DTConfigLUTs.setD(), L1DataEmulDigi.setData(), L1DataEmulDigi.setDEpair(), DDScope.setDepth(), RPCMuon.setDigiIdxVec(), AcceptJet.setEtaMax(), AcceptJet.setEtaMin(), HDRShower.setHit(), edm::service::ELdestControl.setInterval(), AcceptJet.setPRecJetMax(), AcceptJet.setPRecJetMin(), AcceptJet.setPtRecJetMax(), AcceptJet.setPtRecJetMin(), L1DataEmulDigi.setRank(), AcceptJet.setRatioMax(), AcceptJet.setRatioMin(), pftools::ParticleDeposit.setRecEnergy(), RunDCSLVDat.setStatusForBarrel(), RunDCSHVDat.setStatusForBarrel(), RunDCSHVDat.setStatusForEndcaps(), RunDCSLVDat.setStatusForEndcaps(), FP420G4Hit.setTimeSlice(), BscG4Hit.setTimeSlice(), TotemG4Hit.setTimeSlice(), HcalMonitorClient.setupChannelStatusMon(), MuonTrackValidatorBase.setUpVectors(), edm::service::MessageLoggerDefaults.sev_limit(), edm::service::MessageLoggerDefaults.sev_reportEvery(), edm::service::MessageLoggerDefaults.sev_timespan(), SimHitMatcher.simHitsMeanStrip(), hitfit::Top_Decaykin.solve_nu(), hitfit::Top_Decaykin.solve_nu_tmass(), tracking::TempMeasurements.sortIndex(), edm::service::MessageServicePSetValidation.statisticsPSets(), GEMDigiMatcher.stripNumbersInDetId(), TangentHelix.TangentHelix(), reco::PFDisplacedVertexCandidate.testLink(), TestPythiaDecays.TestPythiaDecays(), ThirdHitZPrediction.ThirdHitZPrediction(), edm::service::MessageLoggerDefaults.threshold(), edm::service::MessageLoggerDefaults.timespan(), TkOfflineVariables.TkOfflineVariables(), SeedForPhotonConversionFromQuadruplets.trajectorySeed(), TtDecayChannelSelector.TtDecayChannelSelector(), two_joined_lines(), gen::EvtGenInterface.update_particles(), gen::TauolappInterface.update_particles(), HcalHotCellClient.updateChannelStatus(), HcalDeadCellClient.updateChannelStatus(), FWPFLegoRecHit.updateScale(), reco::TrackGhostTrackState.vertexStateOnGhostTrack(), reco::TrackGhostTrackState.vertexStateOnMeasurement(), VVIObj.VVIObj(), sistripvvi::VVIObj.VVIObj(), VVIObjF.VVIObjF(), GctFormatTranslateMCLegacy.writeAllRctCaloRegionBlock(), GctFormatTranslateMCLegacy.writeGctOutEmAndEnergyBlock(), GctFormatTranslateMCLegacy.writeGctOutJetBlock(), GctFormatTranslateMCLegacy.writeRctEmCandBlocks(), HcalDigiMonitor.zeroCounters(), and TrackerGeometry.~TrackerGeometry().

int ztail.DECOMPRESS_BUF_SIZE = 4

Definition at line 9 of file ztail.py.

string ztail.ENDLINE_MAGIC = "\n"

Definition at line 12 of file ztail.py.

tuple ztail.parser = argparse.ArgumentParser(description='tail, but for gzip files (with Z_FULL_SYNC)')

Definition at line 144 of file ztail.py.