Closed akschaefer closed 5 years ago
I'm surprised this ever worked. When I use save_table
for strings, it crashes, without involving any unicode. Also, the current implementation of load_table
is problematic, because it crashes if f
is not a path.
If we somehow make save_table
work for strings (as @akschaefer managed to do), I think we only have two options:
save_table
ourselves. This could be as simple as copy-and-pasting the numpy code.I'm surprised this ever worked. When I use
save_table
for strings, it crashes, without involving any unicode. Also, the current implementation ofload_table
is problematic, because it crashes iff
is not a path.
Well, for me it somehow works. But it went in hand with a lot of trial and error. Maybe it doesn't work for you because you do not globally declare the encoding?
This is in the header of the python_scripts/comp_to_prev_version.py
, in which the save_table
function is called for strings:
# -*- encoding: utf-8 -*-
If I remember it correctly, it wasn't working properly without this line.
- Raise the required numpy version to 1.14.
This is already the case on master.
But if we leave the numpy version as is, we should maybe add a comment in the end of the readme that this new version is only required for plotting the previous results in the detailed balance plots and not necessary for any analysis. The simulations and analysis can be run when simply decreasing the required numpy version in the top level CMakeLists.txt
Reading the old results for detailed balance currently requires reading unicode strings in 'txt_io.py':
This is however only supported from numpy version 1.14.0 upwards, which is not preinstalled on Kronos and other machines. Hence, the build of the analysis suite fails as the installed version is too old and it needs to be updated manually. It would be nice to find a different representation for those unicode strings such that reading them in is also possible with an older version of numpy and users would not need to update their numpy version when attempting to run the analysis suite.