diff --git a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/CMakeLists.txt b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/CMakeLists.txt
index 49a186f47a7204009e4e08efd2402d4805ccac6e..0dea0a22f87840f7a90e09bedeacd00a158051c3 100644
--- a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/CMakeLists.txt
+++ b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/CMakeLists.txt
@@ -83,3 +83,4 @@ atlas_add_component( ISF_FastCaloSimParametrization
 # Install files from the package:
 atlas_install_python_modules( python/*.py )
 atlas_install_joboptions( share/*.py )
+atlas_install_runtime( scripts/*.py )
diff --git a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/ISF_FastCaloSimParametrization/ISF_HitAnalysis.h b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/ISF_FastCaloSimParametrization/ISF_HitAnalysis.h
index f07595ec60cd6469e10d0dfac5cb6ee742ea612a..594d9549e54e90986449a40c3bd6b655017b2391 100755
--- a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/ISF_FastCaloSimParametrization/ISF_HitAnalysis.h
+++ b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/ISF_FastCaloSimParametrization/ISF_HitAnalysis.h
@@ -174,14 +174,20 @@ class ISF_HitAnalysis : public AthAlgorithm {
    std::vector<std::vector<float> >* m_newTTC_entrance_phi;
    std::vector<std::vector<float> >* m_newTTC_entrance_r;
    std::vector<std::vector<float> >* m_newTTC_entrance_z;
+   std::vector<std::vector<float> >* m_newTTC_entrance_detaBorder;
+   std::vector<std::vector<bool> >* m_newTTC_entrance_OK;
    std::vector<std::vector<float> >* m_newTTC_back_eta;
    std::vector<std::vector<float> >* m_newTTC_back_phi;
    std::vector<std::vector<float> >* m_newTTC_back_r;
    std::vector<std::vector<float> >* m_newTTC_back_z;
+   std::vector<std::vector<float> >* m_newTTC_back_detaBorder;
+   std::vector<std::vector<bool> >* m_newTTC_back_OK;
    std::vector<std::vector<float> >* m_newTTC_mid_eta;
    std::vector<std::vector<float> >* m_newTTC_mid_phi;
    std::vector<std::vector<float> >* m_newTTC_mid_r;
    std::vector<std::vector<float> >* m_newTTC_mid_z;
+   std::vector<std::vector<float> >* m_newTTC_mid_detaBorder;
+   std::vector<std::vector<bool> >* m_newTTC_mid_OK;
    std::vector<float>* m_newTTC_IDCaloBoundary_eta;
    std::vector<float>* m_newTTC_IDCaloBoundary_phi;
    std::vector<float>* m_newTTC_IDCaloBoundary_r;
diff --git a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/python/fcsTrfArgs.py b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/python/fcsTrfArgs.py
new file mode 100644
index 0000000000000000000000000000000000000000..2dfd9fa23929a90b816051283af76b6eb7a0debd
--- /dev/null
+++ b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/python/fcsTrfArgs.py
@@ -0,0 +1,22 @@
+# Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
+
+import argparse
+import logging
+msg = logging.getLogger(__name__)
+import unittest
+import pickle
+import os
+
+from PyJobTransforms.trfArgClasses import argFactory, argFile, argInt, argFloat, argString, argSubstep, trfArgParser, argList, argBool, argPOOLFile, argHITSFile, argRDOFile, argSubstepInt, argSubstepBool
+## Add FCS Ntuple transform arguments
+def addFCS_NtupArgs(parser):
+    parser.defineArgGroup('FCS_Ntup_tf', 'FCS_Ntup_tf specific options')
+    parser.add_argument('--inputESDFile', nargs = '+',
+                        type=argFactory(argPOOLFile, io='input'),
+                        help='Input ESD files', group='FCS_Ntup_tf')
+    parser.add_argument('--outputNTUP_FCSFile', nargs = '+',
+                        type=argFactory(argFile, io='output'),
+                        help='Output NTUP_FCS files', group='FCS_Ntup_tf')
+    parser.add_argument('--outputGeoFileName',
+                        type=argFactory(argString),
+                        help='Optional geometry file', group='FCS_Ntup_tf')
diff --git a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/scripts/FCS_Ntup_tf.py b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/scripts/FCS_Ntup_tf.py
new file mode 100755
index 0000000000000000000000000000000000000000..15f51e0ca815ef0887674b22a8ab900d23bff7a5
--- /dev/null
+++ b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/scripts/FCS_Ntup_tf.py
@@ -0,0 +1,50 @@
+#! /usr/bin/env python
+
+# Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
+
+"""
+Run HITS file and produce histograms.
+"""
+
+import os.path
+import sys
+import time
+import logging
+
+# Setup core logging here
+from PyJobTransforms.trfLogger import msg
+msg.info('logging set in %s' % sys.argv[0])
+from PyJobTransforms.transform import transform
+from PyJobTransforms.trfExe import athenaExecutor
+from PyJobTransforms.trfArgs import addAthenaArguments, addDetectorArguments, addTriggerArguments
+from PyJobTransforms.trfDecorators import stdTrfExceptionHandler, sigUsrStackTrace
+import PyJobTransforms.trfArgClasses as trfArgClasses
+from ISF_FastCaloSimParametrization.fcsTrfArgs import addFCS_NtupArgs
+
+@stdTrfExceptionHandler
+@sigUsrStackTrace
+def main():
+
+    msg.info('This is %s' % sys.argv[0])
+
+    trf = getTransform()
+    trf.parseCmdLineArgs(sys.argv[1:])
+    trf.execute()
+    trf.generateReport()
+
+    msg.info("%s stopped at %s, trf exit code %d" % (sys.argv[0], time.asctime(), trf.exitCode))
+    sys.exit(trf.exitCode)
+
+def getTransform():
+    executorSet = set()
+    executorSet.add(athenaExecutor(name = 'FCS_Ntup',
+                                   skeletonFile = 'ISF_FastCaloSimParametrization/skeleton.ESDtoNTUP_FCS.py',
+                                   inData = ['ESD'], outData = ['NTUP_FCS'],))
+    trf = transform(executor = executorSet, description = 'FastCaloSim V2 Parametrization ntuple transform. Inputs must be ESD. Outputs must bentuple files.')
+    addAthenaArguments(trf.parser)
+    addFCS_NtupArgs(trf.parser)
+    return trf
+
+
+if __name__ == '__main__':
+    main()
diff --git a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/share/ISF_ntuple.py b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/share/ISF_ntuple.py
index d36533ce642ca38994748bddc626b4ed68a7c537..0abd7f6f7c9c50da89fbe409ac468ea4c2515ce8 100644
--- a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/share/ISF_ntuple.py
+++ b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/share/ISF_ntuple.py
@@ -11,107 +11,11 @@ import sys
 from glob import glob
 from AthenaCommon.AthenaCommonFlags  import athenaCommonFlags
 #specify input file here
-#athenaCommonFlags.FilesInput = glob( "ESDpion_eta1.pool.root" )
-#athenaCommonFlags.FilesInput = glob( "ESD_calo__211__E10000_10000__eta20_20_Evts0-1000_z03350.pool.root" )
-#athenaCommonFlags.FilesInput = glob( "ESD_*root" )
-#athenaCommonFlags.FilesInput = ["/afs/cern.ch/user/c/cmills/public/pions20GeV_fulldet.ESD.pool.root"]
-#athenaCommonFlags.FilesInput = ["/afs/cern.ch/user/c/cmills/public/pions20GeV_z0150_fulldet.ESD.pool.root"]
-#athenaCommonFlags.FilesInput = ["root://eosatlas//eos/atlas/user/z/zhubacek/FastCaloSim/ForMichael/ESD_evgen_calo__211_E50000_50000_eta20_25_Evts0-5500_vz_0_origin_calo.pool.root"]
 athenaCommonFlags.FilesInput = ["/afs/cern.ch/work/a/ahasib/public/photon.50GeV.ESD.pool.root"]
 
-ServiceMgr.EventSelector.InputCollections = athenaCommonFlags.FilesInput() # This is stupid and redundant, but necessary
-
-from AthenaCommon.AlgSequence import AlgSequence
-topSequence = AlgSequence()
-
-# To set up a geometry
-from RecExConfig.AutoConfiguration import *
-ConfigureFieldAndGeo() # Configure the settings for the geometry
-include("RecExCond/AllDet_detDescr.py") # Actually load the geometry
-
-from AthenaCommon.DetFlags import DetFlags
-DetFlags.ID_setOn()
-DetFlags.Calo_setOn()
-DetFlags.Muon_setOff()
-DetFlags.Forward_setOff()
-#include ('TrkDetDescrSvc/AtlasTrackingGeometrySvc.py')
-
-from ISF_FastCaloSimParametrization.ISF_FastCaloSimParametrizationConf import ISF_HitAnalysis
-topSequence += ISF_HitAnalysis()
-
-#This can be used to text dump the TruthEvent container
-#from TruthExamples.TruthExamplesConf import DumpMC
-#dumpMC = DumpMC();
-#dumpMC.MCEventKey = "TruthEvent"
-#topSequence += DumpMC(McEventKey = "TruthEvent")
-
-ISF_HitAnalysis = ISF_HitAnalysis()
-ISF_HitAnalysis.NtupleFileName = 'ISF_HitAnalysis'
-
-##############################
-#ISF_HitAnalysis.CaloBoundaryR = [ 0., 1148., 1148., 0. ]
-#ISF_HitAnalysis.CaloBoundaryZ = [ -3475., -3475., 3475., 3475. ]
-
-ISF_HitAnalysis.CaloBoundaryR = 1148.0
-ISF_HitAnalysis.CaloBoundaryZ = 3549.5 #before: 3475.0
-ISF_HitAnalysis.CaloMargin=100 #=10cm
-ISF_HitAnalysis.NTruthParticles = 1 # Copy only one truth particle to the ntuples for now
-#ISF_HitAnalysis.OutputLevel = WARNING
-ISF_HitAnalysis.SaveAllBranches = False
-ISF_HitAnalysis.DoAllCells = False
-ISF_HitAnalysis.DoLayers = True
-ISF_HitAnalysis.DoLayerSums = True
-ISF_HitAnalysis.DoG4Hits = False
-ISF_HitAnalysis.TimingCut = 999999
-ISF_HitAnalysis.OutputLevel = DEBUG
-
-#############################
-##### NEW TRACKING SETUP ####
-#############################
-mlog = logging.getLogger( 'ISF_HitAnalysis::configure:' )
-mlog.info("now configure the non-interacting propagator...")
-from TrkExSTEP_Propagator.TrkExSTEP_PropagatorConf import Trk__STEP_Propagator
-niPropagator = Trk__STEP_Propagator()
-niPropagator.MaterialEffects = False
-ToolSvc+=niPropagator
-mlog.info("configure nono-interacting propagator finished")
-
-mlog.info("now configure the TimedExtrapolator...")
-from TrkExTools.TimedExtrapolator import TimedExtrapolator
-timedExtrapolator=TimedExtrapolator()
-timedExtrapolator.STEP_Propagator = niPropagator
-timedExtrapolator.ApplyMaterialEffects = False
-ToolSvc+=timedExtrapolator
-mlog.info("configure TimedExtrapolator finished")
-
-from CaloTrackingGeometry.CaloTrackingGeometryConf import CaloSurfaceHelper
-caloSurfaceHelper = CaloSurfaceHelper()
-ToolSvc+=caloSurfaceHelper
-
-from TrkDetDescrSvc.TrkDetDescrJobProperties import TrkDetFlags
-
-ISF_HitAnalysis.CaloEntrance=TrkDetFlags.InDetContainerName()
-ISF_HitAnalysis.CaloSurfaceHelper=caloSurfaceHelper
-ISF_HitAnalysis.Extrapolator=timedExtrapolator
-
-#############################
-
-from AthenaCommon.CfgGetter import getPublicTool
-
-#from ISF_FastCaloSimParametrization.ISF_FastCaloSimParametrizationConf import FastCaloSimGeometryHelper
-#FCSgeoHelper=FastCaloSimGeometryHelper()
-#ToolSvc+=FCSgeoHelper
-#ISF_HitAnalysis.CaloGeometryHelper=FCSgeoHelper
-fcsgeohelper= getPublicTool('FastCaloSimGeometryHelper')
-ToolSvc+=fcsgeohelper
-ISF_HitAnalysis.CaloGeometryHelper=fcsgeohelper
-
-ISF_HitAnalysis.FastCaloSimCaloExtrapolation= getPublicTool('FastCaloSimCaloExtrapolation')
-#ISF_HitAnalysis.FastCaloSimCaloExtrapolation.OutputLevel = DEBUG
-#ToolSvc.FastCaloSimCaloExtrapolation.OutputLevel = DEBUG
-ISF_HitAnalysis.FastCaloSimCaloExtrapolation.OutputLevel = ERROR
-ToolSvc.FastCaloSimCaloExtrapolation.OutputLevel = ERROR
+include("ISF_FastCaloSimParametrization/ISF_ntuple_core.py")
 
+theApp.EvtMax = 100 # Set to -1 for all events
 
 from GaudiSvc.GaudiSvcConf import THistSvc
 ServiceMgr += THistSvc()
@@ -122,17 +26,5 @@ print OutputName
 #Use this to automatically name the output file (rename ESD->ISF_HitAnalysis)
 ServiceMgr.THistSvc.Output += [ "ISF_HitAnalysis DATAFILE='"+OutputName+"' OPT='RECREATE'" ]
 from AthenaCommon.GlobalFlags import jobproperties
-ServiceMgr.THistSvc.Output += [ "ISF_Geometry DATAFILE='output_geo.root' OPT='RECREATE'" ]
-
-#ServiceMgr.MessageSvc.OutputLevel = INFO
-ServiceMgr.MessageSvc.OutputLevel = ERROR
-ServiceMgr.MessageSvc.defaultLimit = 9999999
-
-#All events by default
-#theApp.EvtMax = -1
-theApp.EvtMax = 100
-
-ServiceMgr.AuditorSvc.Auditors  += [ "ChronoAuditor"]
+# ServiceMgr.THistSvc.Output += [ "ISF_Geometry DATAFILE='output_geo.root' OPT='RECREATE'" ]
 
-AthenaPoolCnvSvc = Service("AthenaPoolCnvSvc")
-AthenaPoolCnvSvc.UseDetailChronoStat = TRUE
diff --git a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/share/ISF_ntuple_core.py b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/share/ISF_ntuple_core.py
new file mode 100644
index 0000000000000000000000000000000000000000..f72c563bb64ae7a4703a359ef488c45de8bec68e
--- /dev/null
+++ b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/share/ISF_ntuple_core.py
@@ -0,0 +1,98 @@
+from AthenaCommon.AppMgr import ServiceMgr
+import AthenaPoolCnvSvc.ReadAthenaPool
+
+from PartPropSvc.PartPropSvcConf import PartPropSvc
+
+include( "ParticleBuilderOptions/McAOD_PoolCnv_jobOptions.py")
+include( "EventAthenaPool/EventAthenaPool_joboptions.py" )
+
+import os
+import sys
+from glob import glob
+from AthenaCommon.AthenaCommonFlags  import athenaCommonFlags
+
+ServiceMgr.EventSelector.InputCollections = athenaCommonFlags.FilesInput() # This is stupid and redundant, but necessary
+
+from AthenaCommon.AlgSequence import AlgSequence
+topSequence = AlgSequence()
+
+# To set up a geometry
+from RecExConfig.AutoConfiguration import *
+ConfigureFieldAndGeo() # Configure the settings for the geometry
+include("RecExCond/AllDet_detDescr.py") # Actually load the geometry
+
+from AthenaCommon.DetFlags import DetFlags
+DetFlags.ID_setOn()
+DetFlags.Calo_setOn()
+DetFlags.Muon_setOff()
+DetFlags.Forward_setOff()
+
+from ISF_FastCaloSimParametrization.ISF_FastCaloSimParametrizationConf import ISF_HitAnalysis
+topSequence += ISF_HitAnalysis()
+
+ISF_HitAnalysis = ISF_HitAnalysis()
+ISF_HitAnalysis.NtupleFileName = 'ISF_HitAnalysis'
+ISF_HitAnalysis.GeoFileName = 'ISF_Geometry'
+
+##############################
+
+ISF_HitAnalysis.CaloBoundaryR = 1148.0
+ISF_HitAnalysis.CaloBoundaryZ = 3549.5 #before: 3475.0
+ISF_HitAnalysis.CaloMargin=100 #=10cm
+ISF_HitAnalysis.NTruthParticles = 1 # Copy only one truth particle to the ntuples for now
+ISF_HitAnalysis.SaveAllBranches = False
+ISF_HitAnalysis.DoAllCells = False
+ISF_HitAnalysis.DoLayers = True
+ISF_HitAnalysis.DoLayerSums = True
+ISF_HitAnalysis.DoG4Hits = False
+ISF_HitAnalysis.TimingCut = 999999
+ISF_HitAnalysis.OutputLevel = ERROR
+
+#############################
+##### NEW TRACKING SETUP ####
+#############################
+mlog = logging.getLogger( 'ISF_HitAnalysis::configure:' )
+mlog.info("now configure the non-interacting propagator...")
+from TrkExSTEP_Propagator.TrkExSTEP_PropagatorConf import Trk__STEP_Propagator
+niPropagator = Trk__STEP_Propagator()
+niPropagator.MaterialEffects = False
+ToolSvc+=niPropagator
+mlog.info("configure nono-interacting propagator finished")
+
+mlog.info("now configure the TimedExtrapolator...")
+from TrkExTools.TimedExtrapolator import TimedExtrapolator
+timedExtrapolator=TimedExtrapolator()
+timedExtrapolator.STEP_Propagator = niPropagator
+timedExtrapolator.ApplyMaterialEffects = False
+ToolSvc+=timedExtrapolator
+mlog.info("configure TimedExtrapolator finished")
+
+from CaloTrackingGeometry.CaloTrackingGeometryConf import CaloSurfaceHelper
+caloSurfaceHelper = CaloSurfaceHelper()
+ToolSvc+=caloSurfaceHelper
+
+from TrkDetDescrSvc.TrkDetDescrJobProperties import TrkDetFlags
+
+ISF_HitAnalysis.CaloEntrance=TrkDetFlags.InDetContainerName()
+ISF_HitAnalysis.CaloSurfaceHelper=caloSurfaceHelper
+ISF_HitAnalysis.Extrapolator=timedExtrapolator
+
+#############################
+
+from AthenaCommon.CfgGetter import getPublicTool
+
+fcsgeohelper= getPublicTool('FastCaloSimGeometryHelper')
+ToolSvc+=fcsgeohelper
+ISF_HitAnalysis.CaloGeometryHelper=fcsgeohelper
+
+ISF_HitAnalysis.FastCaloSimCaloExtrapolation= getPublicTool('FastCaloSimCaloExtrapolation')
+ISF_HitAnalysis.FastCaloSimCaloExtrapolation.OutputLevel = ERROR
+ToolSvc.FastCaloSimCaloExtrapolation.OutputLevel = ERROR
+
+ServiceMgr.MessageSvc.OutputLevel = ERROR
+ServiceMgr.MessageSvc.defaultLimit = 9999999
+
+ServiceMgr.AuditorSvc.Auditors  += [ "ChronoAuditor"]
+
+AthenaPoolCnvSvc = Service("AthenaPoolCnvSvc")
+AthenaPoolCnvSvc.UseDetailChronoStat = TRUE
\ No newline at end of file
diff --git a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/share/skeleton.ESDtoNTUP_FCS.py b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/share/skeleton.ESDtoNTUP_FCS.py
new file mode 100644
index 0000000000000000000000000000000000000000..9ad54491241ce016cecfde39af06695280d16f14
--- /dev/null
+++ b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/share/skeleton.ESDtoNTUP_FCS.py
@@ -0,0 +1,79 @@
+include("SimuJobTransforms/CommonSkeletonJobOptions.py")
+
+# Get a handle to the ApplicationManager
+from AthenaCommon.AppMgr import theApp
+# Number of events to be processed (default is 10)
+theApp.EvtMax = jobproperties.AthenaCommonFlags.EvtMax.get_Value()
+
+# get the logger
+from AthenaCommon.Logging import logging
+fcsntuplog = logging.getLogger('FCS_Ntup_tf')
+fcsntuplog.info( '****************** STARTING Ntuple Production *****************' )
+fcsntuplog.info( str(runArgs) )
+
+#==============================================================
+# Job definition parameters:
+#==============================================================
+#already in CommonSkeletonJobOptions.py
+#from AthenaCommon.AthenaCommonFlags import athenaCommonFlags
+from AthenaCommon.AppMgr import ToolSvc
+from AthenaCommon.AppMgr import ServiceMgr
+import AthenaPoolCnvSvc.ReadAthenaPool
+
+from PartPropSvc.PartPropSvcConf import PartPropSvc
+
+import os
+from glob import glob
+if hasattr(runArgs,"inputESDFile"):
+    globalflags.InputFormat.set_Value_and_Lock('pool')
+    athenaCommonFlags.FilesInput = runArgs.inputESDFile
+    ServiceMgr.EventSelector.InputCollections = athenaCommonFlags.FilesInput()
+    pass
+
+
+from GaudiSvc.GaudiSvcConf import THistSvc
+ServiceMgr += THistSvc()
+## Output NTUP_FCS File
+if hasattr(runArgs,"outputNTUP_FCSFile"):
+    print "Output is"
+    print  runArgs.outputNTUP_FCSFile
+    ServiceMgr.THistSvc.Output +=["ISF_HitAnalysis DATAFILE='"+runArgs.outputNTUP_FCSFile+"' OPT='RECREATE'"] # FIXME top level directory name
+else:
+    fcsntuplog.warning('No output file set')
+    ServiceMgr.THistSvc.Output +=["ISF_HitAnalysis DATAFILE='output.NTUP_FCS.root' OPT='RECREATE'"] # FIXME top level directory name
+
+
+## Optional output Geometry File
+if hasattr(runArgs,"outputGeoFileName"):
+    ServiceMgr.THistSvc.Output +=["ISF_Geometry DATAFILE='"+runArgs.outputGeoFileName+"' OPT='RECREATE'"] # FIXME top level directory name
+
+
+#==============================================================
+# Job Configuration parameters:
+#==============================================================
+## Pre-exec
+if hasattr(runArgs,"preExec"):
+    fcsntuplog.info("transform pre-exec")
+    for cmd in runArgs.preExec:
+        fcsntuplog.info(cmd)
+        exec(cmd)
+
+## Pre-include
+if hasattr(runArgs,"preInclude"):
+    for fragment in runArgs.preInclude:
+        include(fragment)
+
+
+include("ISF_FastCaloSimParametrization/ISF_ntuple_core.py") # Main job options
+
+## Post-include
+if hasattr(runArgs,"postInclude"):
+    for fragment in runArgs.postInclude:
+        include(fragment)
+
+## Post-exec
+if hasattr(runArgs,"postExec"):
+    digilog.info("transform post-exec")
+    for cmd in runArgs.postExec:
+        fcsntuplog.info(cmd)
+        exec(cmd)
diff --git a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/src/ISF_HitAnalysis.cxx b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/src/ISF_HitAnalysis.cxx
index f5de1ae83d100bf39ae83a01ce1509545169c133..0142ec4d60dee0fa98938182b4b092cd323c574a 100755
--- a/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/src/ISF_HitAnalysis.cxx
+++ b/Simulation/ISF/ISF_FastCaloSim/ISF_FastCaloSimParametrization/src/ISF_HitAnalysis.cxx
@@ -141,14 +141,20 @@ ISF_HitAnalysis::ISF_HitAnalysis(const std::string& name, ISvcLocator* pSvcLocat
    , m_newTTC_entrance_phi(0)
    , m_newTTC_entrance_r(0)
    , m_newTTC_entrance_z(0)
+   , m_newTTC_entrance_detaBorder(0)
+   , m_newTTC_entrance_OK(0)
    , m_newTTC_back_eta(0)
    , m_newTTC_back_phi(0)
    , m_newTTC_back_r(0)
    , m_newTTC_back_z(0)
+   , m_newTTC_back_detaBorder(0)
+   , m_newTTC_back_OK(0)
    , m_newTTC_mid_eta(0)
    , m_newTTC_mid_phi(0)
    , m_newTTC_mid_r(0)
    , m_newTTC_mid_z(0)
+   , m_newTTC_mid_detaBorder(0)
+   , m_newTTC_mid_OK(0)
    , m_newTTC_IDCaloBoundary_eta(0)
    , m_newTTC_IDCaloBoundary_phi(0)
    , m_newTTC_IDCaloBoundary_r(0)
@@ -515,14 +521,20 @@ StatusCode ISF_HitAnalysis::initialize()
   m_newTTC_entrance_phi = new std::vector<std::vector<float> >;
   m_newTTC_entrance_r = new std::vector<std::vector<float> >;
   m_newTTC_entrance_z = new std::vector<std::vector<float> >;
+  m_newTTC_entrance_detaBorder = new std::vector<std::vector<float> >;
+  m_newTTC_entrance_OK = new std::vector<std::vector<bool> >;
   m_newTTC_back_eta = new std::vector<std::vector<float> >;
   m_newTTC_back_phi = new std::vector<std::vector<float> >;
   m_newTTC_back_r = new std::vector<std::vector<float> >;
   m_newTTC_back_z = new std::vector<std::vector<float> >;
+  m_newTTC_back_detaBorder = new std::vector<std::vector<float> >;
+  m_newTTC_back_OK = new std::vector<std::vector<bool> >;
   m_newTTC_mid_eta = new std::vector<std::vector<float> >;
   m_newTTC_mid_phi = new std::vector<std::vector<float> >;
   m_newTTC_mid_r = new std::vector<std::vector<float> >;
   m_newTTC_mid_z = new std::vector<std::vector<float> >;
+  m_newTTC_mid_detaBorder = new std::vector<std::vector<float> >;
+  m_newTTC_mid_OK = new std::vector<std::vector<bool> >;
   m_newTTC_IDCaloBoundary_eta = new std::vector<float>;
   m_newTTC_IDCaloBoundary_phi = new std::vector<float>;
   m_newTTC_IDCaloBoundary_r = new std::vector<float>;
@@ -600,14 +612,20 @@ StatusCode ISF_HitAnalysis::initialize()
   m_tree->Branch("newTTC_back_phi",&m_newTTC_back_phi);
   m_tree->Branch("newTTC_back_r",&m_newTTC_back_r);
   m_tree->Branch("newTTC_back_z",&m_newTTC_back_z);
+  m_tree->Branch("newTTC_back_detaBorder",&m_newTTC_back_detaBorder);
+  m_tree->Branch("newTTC_back_OK",&m_newTTC_back_OK);
   m_tree->Branch("newTTC_entrance_eta",&m_newTTC_entrance_eta);
   m_tree->Branch("newTTC_entrance_phi",&m_newTTC_entrance_phi);
   m_tree->Branch("newTTC_entrance_r",&m_newTTC_entrance_r);
   m_tree->Branch("newTTC_entrance_z",&m_newTTC_entrance_z);
+  m_tree->Branch("newTTC_entrance_detaBorder",&m_newTTC_entrance_detaBorder);
+  m_tree->Branch("newTTC_entrance_OK",&m_newTTC_entrance_OK);
   m_tree->Branch("newTTC_mid_eta",&m_newTTC_mid_eta);
   m_tree->Branch("newTTC_mid_phi",&m_newTTC_mid_phi);
   m_tree->Branch("newTTC_mid_r",&m_newTTC_mid_r);
   m_tree->Branch("newTTC_mid_z",&m_newTTC_mid_z);
+  m_tree->Branch("newTTC_mid_detaBorder",&m_newTTC_mid_detaBorder);
+  m_tree->Branch("newTTC_mid_OK",&m_newTTC_mid_OK);
   m_tree->Branch("newTTC_IDCaloBoundary_eta",&m_newTTC_IDCaloBoundary_eta);
   m_tree->Branch("newTTC_IDCaloBoundary_phi",&m_newTTC_IDCaloBoundary_phi);
   m_tree->Branch("newTTC_IDCaloBoundary_r",&m_newTTC_IDCaloBoundary_r);
@@ -791,14 +809,20 @@ StatusCode ISF_HitAnalysis::execute()
  m_newTTC_back_phi->clear();
  m_newTTC_back_r->clear();
  m_newTTC_back_z->clear();
+ m_newTTC_back_detaBorder->clear();
+ m_newTTC_back_OK->clear();
  m_newTTC_entrance_eta->clear();
  m_newTTC_entrance_phi->clear();
  m_newTTC_entrance_r->clear();
  m_newTTC_entrance_z->clear();
+ m_newTTC_entrance_detaBorder->clear();
+ m_newTTC_entrance_OK->clear();
  m_newTTC_mid_eta->clear();
  m_newTTC_mid_phi->clear();
  m_newTTC_mid_r->clear();
  m_newTTC_mid_z->clear();
+ m_newTTC_mid_detaBorder->clear();
+ m_newTTC_mid_OK->clear();
  m_newTTC_IDCaloBoundary_eta->clear();
  m_newTTC_IDCaloBoundary_phi->clear();
  m_newTTC_IDCaloBoundary_r->clear();
@@ -960,16 +984,22 @@ StatusCode ISF_HitAnalysis::execute()
                  std::vector<float> phi_vec_ENT;
                  std::vector<float> r_vec_ENT;
                  std::vector<float> z_vec_ENT;
+                 std::vector<float> detaBorder_vec_ENT;
+                 std::vector<bool>  OK_vec_ENT;
 
      std::vector<float> eta_vec_EXT;
                  std::vector<float> phi_vec_EXT;
                  std::vector<float> r_vec_EXT;
                  std::vector<float> z_vec_EXT;
+                 std::vector<float> detaBorder_vec_EXT;
+                 std::vector<bool>  OK_vec_EXT;
 
      std::vector<float> eta_vec_MID;
                  std::vector<float> phi_vec_MID;
                  std::vector<float> r_vec_MID;
                  std::vector<float> z_vec_MID;
+                 std::vector<float> detaBorder_vec_MID;
+                 std::vector<bool>  OK_vec_MID;
 
      float phi_MID;
 
@@ -980,6 +1010,8 @@ StatusCode ISF_HitAnalysis::execute()
                         ATH_MSG_DEBUG(" phi ENT "<<result.phi(sample,1)<<" phi EXT "<<result.phi(sample,2));
                         ATH_MSG_DEBUG(" r   ENT "<<result.r(sample,1)  <<" r   EXT "<<result.r(sample,2)  );
                         ATH_MSG_DEBUG(" z   ENT "<<result.z(sample,1)  <<" z   EXT "<<result.z(sample,2)  );
+                        ATH_MSG_DEBUG(" detaBorder   ENT "<<result.detaBorder(sample,1)  <<" detaBorder   EXT "<<result.detaBorder(sample,2)  );
+                        ATH_MSG_DEBUG(" OK   ENT "<<result.OK(sample,1)  <<" OK   EXT "<<result.OK(sample,2)  );
                         eta_vec_ENT.push_back(float(result.eta(sample,1)));
                         eta_vec_EXT.push_back(float(result.eta(sample,2)));
                         eta_vec_MID.push_back(float((result.eta(sample,1)+result.eta(sample,2))/2));
@@ -997,20 +1029,32 @@ StatusCode ISF_HitAnalysis::execute()
                         z_vec_ENT.push_back(float(result.z(sample,1)));
                         z_vec_EXT.push_back(float(result.z(sample,2)));
                         z_vec_MID.push_back(float((result.z(sample,1)+result.z(sample,2))/2));
+                        detaBorder_vec_ENT.push_back(float(result.detaBorder(sample,1)));
+                        detaBorder_vec_EXT.push_back(float(result.detaBorder(sample,2)));
+                        detaBorder_vec_MID.push_back(float((result.detaBorder(sample,1)+result.detaBorder(sample,2))/2));
+                        OK_vec_ENT.push_back(float(result.OK(sample,1)));
+                        OK_vec_EXT.push_back(float(result.OK(sample,2)));
+                        OK_vec_MID.push_back(float(result.OK(sample,1)&&result.OK(sample,2)));
      }
 
      m_newTTC_back_eta->push_back(eta_vec_EXT);
                  m_newTTC_back_phi->push_back(phi_vec_EXT);
                  m_newTTC_back_r  ->push_back(r_vec_EXT);
                  m_newTTC_back_z  ->push_back(z_vec_EXT);
+                 m_newTTC_back_detaBorder  ->push_back(detaBorder_vec_EXT);
+                 m_newTTC_back_OK  ->push_back(OK_vec_EXT);
                  m_newTTC_entrance_eta->push_back(eta_vec_ENT);
                  m_newTTC_entrance_phi->push_back(phi_vec_ENT);
                  m_newTTC_entrance_r  ->push_back(r_vec_ENT);
                  m_newTTC_entrance_z  ->push_back(z_vec_ENT);
+                 m_newTTC_entrance_detaBorder  ->push_back(detaBorder_vec_ENT);
+                 m_newTTC_entrance_OK  ->push_back(OK_vec_ENT);
                  m_newTTC_mid_eta->push_back(eta_vec_MID);
                  m_newTTC_mid_phi->push_back(phi_vec_MID);
                  m_newTTC_mid_r  ->push_back(r_vec_MID);
                  m_newTTC_mid_z  ->push_back(z_vec_MID);
+                 m_newTTC_mid_detaBorder  ->push_back(detaBorder_vec_MID);
+                 m_newTTC_mid_OK  ->push_back(OK_vec_MID);
 
      //*******************************************************************************************************************************