Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Thomas Kluyver
Pycrystfel
Commits
1932e760
Commit
1932e760
authored
Jan 08, 2021
by
Thomas Kluyver
Browse files
Set empty map for bad regions
parent
6b527a89
Changes
1
Hide whitespace changes
Inline
Side-by-side
pycrystfel/bindings.pyx
View file @
1932e760
import
os
from
libc.stdlib
cimport
malloc
,
free
cimport
numpy
as
cnp
from
.
cimport
crystfel
...
...
@@ -22,7 +23,9 @@ def find_peaks_single_panel(cnp.ndarray[cnp.npy_float, ndim=2] data, str geom_fi
crystfel
.
image
image
image
.
dp
[
0
]
=
<
float
*>
data
.
data
image
.
bad
[
0
]
=
<
int
*>
malloc
(
data
.
size
*
sizeof
(
int
))
image
.
det
=
crystfel
.
get_detector_geometry
(
os
.
fsencode
(
geom_file
),
&
beam
)
print
(
f
"Loaded geometry with
{
image
.
det
.
n_panels
}
panels"
)
crystfel
.
search_peaks_peakfinder8
(
&
image
,
max_n_peaks
=
200
,
threshold
=
20
,
min_snr
=
3
,
min_pix_count
=
2
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment