Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Iaroslav Igoshev <[email protected]>
  • Loading branch information
Retribution98 and YarShev authored Nov 7, 2023
1 parent e51e133 commit ca25f6a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions unidist/core/backends/mpi/core/shared_object_store.py
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ def _allocate_shared_memory(self):
# To avoid division by 0
if MpiSharedObjectStoreThreshold.get() > 0:
self.service_memory_size = min(
# allowd memory for serivce buffer
# allowed memory size for service buffer
allowed_memory_size - self.shared_memory_size,
# maximum amount of memory required for the service buffer
(self.shared_memory_size // MpiSharedObjectStoreThreshold.get())
Expand Down Expand Up @@ -216,7 +216,7 @@ def _allocate_shared_memory(self):

if self.shared_memory_size + self.service_memory_size > allowed_memory_size:
raise ValueError(
"The sum of the `MpiSharedObjectStoreMemory` and `MpiSharedServiceMemory` values is greater than the amount of memory that exists."
"The sum of the `MpiSharedObjectStoreMemory` and `MpiSharedServiceMemory` values is greater than the available amount of memory."
)

# Shared memory is allocated only once by the monitor process.
Expand Down

0 comments on commit ca25f6a

Please sign in to comment.