mirror of
https://github.com/codex-storage/nim-codex.git
synced 2025-02-08 02:55:05 +00:00
use correct dataset geometry in erasure
This commit is contained in:
parent
947b3dadc0
commit
90acd52d1d
@ -241,7 +241,7 @@ proc init*(
|
||||
|
||||
let
|
||||
rounded = roundUp(manifest.blocksCount, ecK)
|
||||
steps = divUp(manifest.blocksCount, ecK)
|
||||
steps = divUp(rounded, ecK)
|
||||
blocksCount = rounded + (steps * ecM)
|
||||
|
||||
success EncodingParams(
|
||||
|
@ -31,7 +31,7 @@ func `==`*(a, b: Block): bool =
|
||||
proc calcEcBlocksCount*(blocksCount: int, ecK, ecM: int): int =
|
||||
let
|
||||
rounded = roundUp(blocksCount, ecK)
|
||||
steps = divUp(blocksCount, ecK)
|
||||
steps = divUp(rounded, ecK)
|
||||
|
||||
rounded + (steps * ecM)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user