Skip to content
Snippets Groups Projects
Commit e090f70a authored by Daniel Bauer's avatar Daniel Bauer :speech_balloon:
Browse files

distinguish casts (scalar -> vector) and (vector -> vector)

parent 09a932f1
No related branches found
No related tags found
No related merge requests found
...@@ -678,7 +678,7 @@ class VectorizedCustomSympyPrinter(CustomSympyPrinter): ...@@ -678,7 +678,7 @@ class VectorizedCustomSympyPrinter(CustomSympyPrinter):
else: else:
if arg.is_Number and not isinstance(arg, (sp.core.numbers.Infinity, sp.core.numbers.NegativeInfinity)): if arg.is_Number and not isinstance(arg, (sp.core.numbers.Infinity, sp.core.numbers.NegativeInfinity)):
return self._typed_vectorized_number(arg, data_type) return self._typed_vectorized_number(arg, data_type)
elif isinstance(arg, TypedSymbol): elif isinstance(arg, TypedSymbol) and not isinstance(arg.dtype, VectorType):
return self._typed_vectorized_symbol(arg, data_type) return self._typed_vectorized_symbol(arg, data_type)
elif isinstance(arg, (InverseTrigonometricFunction, TrigonometricFunction, HyperbolicFunction)) \ elif isinstance(arg, (InverseTrigonometricFunction, TrigonometricFunction, HyperbolicFunction)) \
and base_type == BasicType('float32'): and base_type == BasicType('float32'):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment