Explorar el Código

startup: setup pretty printing for sympy expressions

Fabian Peter Hammerle hace 4 años
padre
commit
88f8af8ef2
Se han modificado 1 ficheros con 4 adiciones y 0 borrados
  1. 4 0
      profile_default/startup/init.py

+ 4 - 0
profile_default/startup/init.py

@@ -4,8 +4,12 @@ import typing
 
 import numpy
 import scipy.io.wavfile
+import sympy
 from matplotlib import pyplot  # pylint: disable=unused-import; frequently used in shell
 
+# https://docs.sympy.org/latest/modules/interactive.html#module-sympy.interactive.printing
+sympy.init_printing(pretty_print=True)
+
 
 def numpy_array_from_file(
     path: typing.Union[str, pathlib.Path], dtype