Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
ToolBox
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
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
Thomas Kluyver
ToolBox
Commits
1ab94b57
Commit
1ab94b57
authored
5 years ago
by
Loïc Le Guyader
Browse files
Options
Downloads
Patches
Plain Diff
small fixes
parent
3dc50e85
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
DSSC.py
+15
-1
15 additions, 1 deletion
DSSC.py
__init__.py
+1
-1
1 addition, 1 deletion
__init__.py
azimuthal_integrator.py
+1
-0
1 addition, 0 deletions
azimuthal_integrator.py
with
17 additions
and
2 deletions
DSSC.py
+
15
−
1
View file @
1ab94b57
...
...
@@ -9,11 +9,12 @@ import warnings
import
karabo_data
as
kd
from
karabo_data.geometry2
import
DSSC_1MGeometry
import
ToolBox
as
tb
import
matplotlib.pyplot
as
plt
import
numpy
as
np
import
xarray
as
xr
import
matplotlib.pyplot
as
plt
import
h5py
from
imageio
import
imread
class
DSSC
:
...
...
@@ -214,6 +215,19 @@ class DSSC:
path
=
'
/gpfs/exfel/sw/software/exfel_environments/misc/git/karabo_data/docs/dssc_geo_june19.h5
'
geom
=
DSSC_1MGeometry
.
from_h5_file_and_quad_positions
(
path
,
quad_pos
)
return
geom
def
load_mask
(
self
,
fname
):
"""
Load a DSSC mask file.
input:
fname: string of the filename of the mask file
"""
dssc_mask
=
imread
(
fname
)
dssc_mask
=
dssc_mask
.
astype
(
float
)[...,
0
]
//
255
dssc_mask
[
dssc_mask
==
0
]
=
np
.
nan
self
.
mask
=
dssc_mask
def
create_virtual_dssc_datasets
(
self
,
run
,
path
=
''
):
"""
Create virtual datasets for each 16 DSSC modules used for the multiprocessing.
...
...
This diff is collapsed.
Click to expand it.
__init__.py
+
1
−
1
View file @
1ab94b57
...
...
@@ -4,4 +4,4 @@ from ToolBox.XAS import *
from
ToolBox.knife_edge
import
*
from
ToolBox.Laser_utils
import
*
from
ToolBox.DSSC
import
DSSC
from
ToolBox.azimuthal_integrator
import
azimuthal_integrator
from
ToolBox.azimuthal_integrator
import
*
This diff is collapsed.
Click to expand it.
azimuthal_integrator.py
+
1
−
0
View file @
1ab94b57
import
numpy
as
np
class
azimuthal_integrator
(
object
):
def
__init__
(
self
,
imageshape
,
center
,
polar_range
,
dr
=
2
):
...
...
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