-
Notifications
You must be signed in to change notification settings - Fork 198
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
Add binary sufixes to job tools memory specification (e.g. 1GiB vs 1GB) #2858
Merged
samuelgarcia
merged 1 commit into
SpikeInterface:main
from
h-mayorquin:binary_iec_prefixes
May 21, 2024
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@h-mayorquin I think that this might make things extra complicated. If I understand correctly,
1KB = 1000 bytes
1KiB = 1024 bytes
Is that correct? I had to look up the difference between decimal/binary for memory representation, so I think that an end user could be a bit puzzled by this.
Happy to discuss!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think that having the two is confusing indeed.
But the current setup is confusing as well. If somebody allocates 1G using the current SpikeInterface machinery (and SpikeInterface was perfect in its handling of memory ...) the memory reported by the system won't match 1G as the user specified.
The reason for this is that RAM memory is reported in binary base. Both when you buy RAM and when you use utilities like system resource, the numbers you see are in binary base. .
Given that memory allocation here is a RAM issue, I think we should follow the convention of RAM specification (binary). However, we have to do things carefully because the decimal base has been there for so long.
Finally, given that using the job_kwargs is a relatively advanced feature, I am far less concerned about this type of confusion and I am fine with having the user specify which one they want to use.
(Hard drive storage, on the other hand, is reported in base 10, both when you calculate the size of an object in the system and when you buy a hard drive, here some link to the discssion on why this might be confusing for hard drives as well: https://superuser.com/questions/1080633/confusion-with-storage-capacity-powers-of-10-and-2)