Skip to content
Snippets Groups Projects
Commit 48b46791 authored by Kaushik Kulkarni's avatar Kaushik Kulkarni
Browse files

prefer np.isscalar(s) over isinstance(s, Number)

parent 0980f4b2
No related branches found
No related tags found
No related merge requests found
......@@ -303,8 +303,7 @@ class PytatoExecutable:
# {{{ extract loopy arguments execute the program
for pos, arg in enumerate(args):
if isinstance(arg, np.number):
if np.isscalar(arg):
input_kwargs_to_loopy[self.input_id_to_name_in_program[(pos,)]] = (
cla.to_device(self.actx.queue, np.array(arg)))
elif is_array_container(arg):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment