Skip to content

Commit

Permalink
Renamed allocation file to allocation.pkl.gz as suggested by matz-e
Browse files Browse the repository at this point in the history
  • Loading branch information
st4rl3ss committed Feb 13, 2024
1 parent ded837b commit e5aa8d4
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docs/architecture.rst
Original file line number Diff line number Diff line change
Expand Up @@ -413,7 +413,7 @@ and fast. The algorithm is as follows:

The user can specify the number of ranks to target using the `--num-target-ranks` flag in the CLI of neurodamus.
The default value is 40. The allocation dictionary, containing the assignment of gids to ranks per each population,
is then saved to the `allocation.gz` file in a pickled gzipped format. In the near future users will be able to
is then saved to the `allocation.pkl.gz` file in a pickled gzipped format. In the near future users will be able to
import this data in any following simulation in order to improve the memory balance.

Development
Expand Down
2 changes: 1 addition & 1 deletion neurodamus/utils/memory.py
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,7 @@ def get_memory_usage(cls, count, synapse_type):

class DryRunStats:
_MEMORY_USAGE_FILENAME = "cell_memory_usage.json"
_ALLOCATION_FILENAME = "allocation.gz"
_ALLOCATION_FILENAME = "allocation.pkl.gz"

def __init__(self) -> None:
self.metype_memory = {}
Expand Down
4 changes: 2 additions & 2 deletions tests/integration-e2e/test_dry_run_worflow.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ def test_dry_run_workflow(USECASE3):

# Test that the allocation works and can be saved and loaded
rank_allocation, _ = nd._dry_run_stats.distribute_cells(2)
export_allocation_stats(rank_allocation, USECASE3 / "allocation.gz")
rank_allocation = import_allocation_stats(USECASE3 / "allocation.gz")
export_allocation_stats(rank_allocation, USECASE3 / "allocation.pkl.gz")
rank_allocation = import_allocation_stats(USECASE3 / "allocation.pkl.gz")
rank_allocation_standard = convert_to_standard_types(rank_allocation)

expected_items = {
Expand Down

0 comments on commit e5aa8d4

Please sign in to comment.