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
Bliss
bliss
Commits
22b1dba5
Commit
22b1dba5
authored
Jun 09, 2021
by
Valentin Valls
Browse files
Make sure the numpy array is writable
parent
f0c3e63a
Changes
1
Hide whitespace changes
Inline
Side-by-side
bliss/flint/client/plots.py
View file @
22b1dba5
...
...
@@ -70,6 +70,15 @@ class BasePlot(object):
def
update_data
(
self
,
field
,
data
):
data_dict
=
self
.
data
()
# Data from the network is sometime not writable
# This make it fail silx for some use cases
if
data
is
None
:
return
None
if
isinstance
(
data
,
numpy
.
ndarray
):
if
not
data
.
flags
.
writeable
:
data
=
numpy
.
array
(
data
)
data_dict
[
field
]
=
data
def
remove_data
(
self
,
field
):
...
...
Write
Preview
Supports
Markdown
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