Skip to content

Instantly share code, notes, and snippets.

View neggert's full-sized avatar

Nic Eggert neggert

View GitHub Profile
@neggert
neggert / inception_v3.py
Created April 6, 2016 17:35
Inception-v3 implementation in Keras
from keras.models import Model
from keras.layers import (
Input,
Dense,
Flatten,
merge,
Lambda
)
from keras.layers.convolutional import (
Convolution2D,
[ 92%] Generating gm2dataproducts_calo_dict.cpp, gm2dataproducts_calo_map.cpp
--->> genreflex: INFO: Using gccxml from /gm2/app/software/prod/external/gccxml/v0_9_20120702/Linux64bit+2.6-2.5-gcc47/bin/gccxml
--->> genreflex: INFO: Parsing file /gm2/app/users/eggert/playing/srcs/gm2dataproducts/calo/classes.h with GCC_XML OK
--->> genreflex: INFO: Generating Reflex Dictionary
class gm2dataproducts::XtalHitClusterArtRecord
class std::vector<gm2dataproducts::XtalHitClusterArtRecord>
class art::PtrVector<gm2ringsim::XtalArtRecord>
class art::Wrapper<std::vector<gm2dataproducts::XtalHitClusterArtRecord> >
class art::Ptr<gm2ringsim::XtalArtRecord>
[ 92%] Building CXX object gm2dataproducts/calo/CMakeFiles/gm2dataproducts_calo_dict.dir/gm2dataproducts_calo_dict.cpp.o
+++ Starting PROOF-Lite with 8 workers +++
Opening connections to workers: OK (8 workers)
Setting up worker servers: OK (8 workers)
PROOF set to parallel mode (8 workers)
TBufferFile::WriteObjectAny:0: RuntimeWarning: since RooNumCdf has no public constructor
which can be called without argument, objects of this class
can not be read with the current library. You will need to
add a default constructor before attempting to read it.
TBufferFile::WriteObjectAny:0: RuntimeWarning: since RooNumCdf has no public constructor
which can be called without argument, objects of this class
===================== glite-job-logging-info Success =====================
LOGGING INFORMATION:
Printing info for the Job : https://wms309.cern.ch:9000/EHTWzFN0kL288AvLiTVx9A
---
Event: RegJob
- Arrived = Thu Feb 21 13:54:15 2013 CST
@neggert
neggert / AndersonDarlingTestStat.cc
Last active December 11, 2015 10:28
Anderson-Darling Test Statistic for use in RooStats. This has only been tested on the model I produced using HistFactory, so YMMV. In particularl, it only works on binned data, although modifications to make it work on unbinned data would be minimal. Fixes and forks are welcome.
#include "AndersonDarlingTestStat.h"
#include "RooStats/RooStatsUtils.h"
#include "RooMsgService.h"
#include "TMath.h"
#include <utility>
using namespace std;
typedef pair<Double_t, Double_t> double_pair;
@neggert
neggert / gist:3691954
Created September 10, 2012 16:31
stacked_step_hist tests
"""
..K...K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K.EEE.K............K..K..K..K..K..K..KK.................................................................K......K..K...K.K..KK...K..K..K......................................................................................................................................................................................K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K..K
def get_seu_logs()
# get the portion of the logs relevant to the seu
logs = []
Dir['**/PixelFEDSupervisor_*.log'].each do |path|
contents = File.read(path)
regex = /Message : Detected soft error using FED channel monitoring(.*?)Message : New state is:Running/m
matches = contents.scan(regex)
if (matches != nil)
(0..matches.size-1).each do |i|
cms-sh|1> info run=160915
---------------------------------------------------------------------------
HTTPError Traceback (most recent call last)
/afs/cern.ch/user/n/neggert/<ipython-input-1-c10902d46b4c> in <module>()
----> 1 get_ipython().magic(u'info run=160915')
/afs/cern.ch/work/v/valya/public/soft/install/lib/python2.6/site-packages/IPython/core/interactiveshell.pyc in magic(self, arg_s, next_input)
1983 self._magic_locals = sys._getframe(1).f_locals
1984 with self.builtin_trap:
-> 1985 result = fn(magic_args)
cms-sh|5> info run=160915
---------------------------------------------------------------------------
HTTPError Traceback (most recent call last)
/afs/cern.ch/user/n/neggert/<ipython-input-5-c10902d46b4c> in <module>()
----> 1 get_ipython().magic(u'info run=160915')
/afs/cern.ch/work/v/valya/public/soft/install/lib/python2.6/site-packages/IPython/core/interactiveshell.pyc in magic(self, arg_s, next_input)
1983 self._magic_locals = sys._getframe(1).f_locals
1984 with self.builtin_trap:
-> 1985 result = fn(magic_args)
229:cms+cmssw-tool-conf+25.########################################### [100%]
230:cms+cmssw+CMSSW_5_2_0 ########################################### [100%]
Done.
Create user area for CMSSW_5_2_0 release ...
Enter PEM pass phrase:
/bin/sh: scramv1: command not found
---------------------------------------------------------------------------
OSError Traceback (most recent call last)
/Users/nic/cms/soft/Releases/<ipython-input-1-f0d9fe6489f2> in <module>()
----> 1 get_ipython().magic(u'install CMSSW_5_2_0')