From 583b4da8534e307da97a1a57ed0955af2388b7b0 Mon Sep 17 00:00:00 2001
From: fuchenxi <1256257282@qq.com>
Date: Thu, 10 Oct 2024 16:15:22 +0800
Subject: [PATCH] =?UTF-8?q?=E5=88=A0=E9=99=A4=E6=AE=8B=E4=BD=99=E4=BB=A3?=
 =?UTF-8?q?=E7=A0=81?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 current/cal_current.py   |  2 +-
 particle/carrier_list.py | 26 ++------------------------
 2 files changed, 3 insertions(+), 25 deletions(-)

diff --git a/current/cal_current.py b/current/cal_current.py
index 61ca845..1503432 100644
--- a/current/cal_current.py
+++ b/current/cal_current.py
@@ -16,7 +16,7 @@ import numpy as np
 import ROOT
 
 from .model import Material
-from particle.carrier_list import CarrierListFromG4P, StripCarrierListFromG4P
+from particle.carrier_list import CarrierListFromG4P
 from util.math import Vector, signal_convolution
 from util.output import create_path
 
diff --git a/particle/carrier_list.py b/particle/carrier_list.py
index 27f430c..ecbfc63 100644
--- a/particle/carrier_list.py
+++ b/particle/carrier_list.py
@@ -38,6 +38,7 @@ class CarrierListFromG4P:
                 raise ValueError
             
         elif batch == 0 and my_g4p.geant4_model == "Si_strip":
+            # P13 cut condition
             h1 = ROOT.TH1F("Edep_device", "Energy deposition in Detector", 100, 0, max(my_g4p.edep_devices)*1.1)
             for i in range (len(my_g4p.edep_devices)):
                 h1.Fill(my_g4p.edep_devices[i])
@@ -67,27 +68,4 @@ class CarrierListFromG4P:
         self.tracks_step = my_g4p.energy_steps[j]
         self.tracks_t_energy_deposition = my_g4p.edep_devices[j] #涓轰粈涔堜笉浣跨敤锛�
         self.ionized_pairs = [step*1e6/self.energy_loss for step in self.tracks_step]
-    
-
-class StripCarrierListFromG4P:
-    # P13 cut condition
-    def __init__(self, material, my_g4p, batch):
-        if (material == "SiC"):
-            self.energy_loss = 8.4 #ev
-        elif (material == "Si"):
-            self.energy_loss = 3.6 #ev
-
-        
-
-            if batch == 0:
-                print("=========RASER info ===========\nGeant4:the sensor didn't have particles hitted\n==========================")
-                raise ValueError
-        else:
-            self.batch_def(my_g4p,batch)
-
-    def batch_def(self,my_g4p,j):
-        self.beam_number = j
-        self.track_position = [[single_step[0],single_step[1],single_step[2],1e-9] for single_step in my_g4p.p_steps_current[j]]
-        self.tracks_step = my_g4p.energy_steps[j]
-        self.tracks_t_energy_deposition = my_g4p.edep_devices[j] #涓轰粈涔堜笉浣跨敤锛�
-        self.ionized_pairs = [step*1e6/self.energy_loss for step in self.tracks_step]
+    
\ No newline at end of file
-- 
GitLab