Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Long parameter names get truncated #269

Closed
joAschauer opened this issue Aug 3, 2021 · 3 comments
Closed

Long parameter names get truncated #269

joAschauer opened this issue Aug 3, 2021 · 3 comments

Comments

@joAschauer
Copy link

Hi there,
thanks for the great package. I am calibrating a model with somewhat long parameter names and spotpy truncates the names internally. This is a bit annoying when the found parameters are intended to be used later on or when parameter names are referenced in the ´simulation()´ method of the Setup class.

The truncation is defined here:

dtype = [('random', '<f8'), ('name', '|U30'),

Is there any reasoning why you introduced the 30 character limit?

@thouska
Copy link
Owner

thouska commented Sep 6, 2021

Hi @joAschauer ,
thank you for this error report. You are right, there was no particular reason, to introduce this 30 character limit. Which limit would suit you? I can publish a new version accordingly.

@joAschauer
Copy link
Author

Hello @thouska,
thanks for your reply. I don't know which limit would be suitable... You could go for a 100 character limit which I'd assume should suffice for most people.

@thouska
Copy link
Owner

thouska commented Sep 9, 2021

100 characters sounds like a good suggestion, I changed the values accordingly.
As the database saved values with a resolution of np.float16 by default, I also increased that setting to np.float32. This should, hopefully, prevent most errors, which are related to truncation of data.

@thouska thouska closed this as completed Sep 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants