Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
P
PasantiasLaCOnGA_2022
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Wiki
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Yessica Dominguez
PasantiasLaCOnGA_2022
Commits
5f1af77a
Commit
5f1af77a
authored
2 years ago
by
Yessica Dominguez
Browse files
Options
Downloads
Patches
Plain Diff
Upload New File
parent
f14e5507
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
HumedadConNeutrones/codigos python/EspectroUranos.py
+45
-0
45 additions, 0 deletions
HumedadConNeutrones/codigos python/EspectroUranos.py
with
45 additions
and
0 deletions
HumedadConNeutrones/codigos python/EspectroUranos.py
0 → 100644
+
45
−
0
View file @
5f1af77a
import
pandas
as
pd
import
numpy
as
np
import
matplotlib.pyplot
as
plt
dlayer
=
pd
.
read_table
(
'
detectorLayer300000.dat
'
)
df1
=
dlayer
[
dlayer
[
'
Soil_contact
'
]
==
1
]
# contacto con el suelo
df5
=
df1
[
df1
[
'
previous_Depth_[m]
'
]
>
0.0
]
# espero que vengan del suelo
dfinal
=
pd
.
DataFrame
()
dfback
=
df5
[
df5
[
'
z_[m]
'
]
==
-
2.0
]
# espero que vengan del suelo (Back scattering)
dfin
=
dlayer
.
drop_duplicates
([
'
Neutron_Number
'
],
keep
=
'
first
'
)
# espero que sean solo los incoming
dfinal
[
'
E
'
]
=
pd
.
concat
([
dfin
[
'
Energy_at_Interface_[MeV]
'
],
dfback
[
'
Energy_[MeV]
'
]],
axis
=
0
)
#TOTAL dfin + dfback
#LOG para todos
dlayer
=
dfinal
.
assign
(
energy
=
np
.
log
(
dfinal
[
'
E
'
]))
#azul (TOTAL)
dback
=
dfback
.
assign
(
energy
=
np
.
log
(
dfback
[
'
Energy_[MeV]
'
]))
# Green (Back Scattered)
din
=
dfin
.
assign
(
energy
=
np
.
log
(
dfin
[
'
Energy_at_Interface_[MeV]
'
]))
# naranja (INCOMING)
#############
print
(
len
(
dfin
.
index
))
print
(
len
(
dfback
.
index
))
a
=
780
dlayer
[
'
energy
'
].
hist
(
bins
=
int
(
a
*
1.17
),
histtype
=
'
step
'
,
label
=
'
Total
'
,
linewidth
=
1
)
#azul
din
[
'
energy
'
].
hist
(
bins
=
a
,
histtype
=
'
step
'
,
label
=
'
Incoming Spectrum
'
,
linewidth
=
1
)
#Naranja
dback
[
'
energy
'
].
hist
(
bins
=
a
,
histtype
=
'
step
'
,
label
=
'
Backscattered Spectrum
'
,
linewidth
=
1
)
#verde
x
=
[
-
np
.
log
(
100000000
),
-
np
.
log
(
1000000
),
-
np
.
log
(
10000
),
-
np
.
log
(
100
),
np
.
log
(
1
),
np
.
log
(
100
)]
val
=
[
'
1e-8
'
,
'
1e-6
'
,
'
1e-4
'
,
'
0.01
'
,
'
1
'
,
'
100
'
]
plt
.
title
(
'
URANOS Neutron Spectra
'
,
loc
=
'
center
'
)
plt
.
xlabel
(
'
Energy(MeV)
'
,
size
=
13
)
plt
.
ylabel
(
'
Counts
'
,
size
=
13
)
plt
.
tick_params
(
labelsize
=
14
)
plt
.
xticks
(
x
,
val
)
plt
.
legend
(
loc
=
'
upper left
'
)
plt
.
show
()
#y = [500,1000,1500,2000,2500,3000]
#valy = ['0.5','1','1.5','2.0','2.5','3.0']
#plt.title('e+3', loc = 'left')
#plt.yticks(y,valy)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment