Skip to content

Commit

Permalink
fix TreeRC
Browse files Browse the repository at this point in the history
  • Loading branch information
LexLuthr committed May 7, 2024
1 parent a84fe9b commit 64686d9
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
3 changes: 3 additions & 0 deletions curiosrc/seal/task_treed.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,9 @@ type TreeDTask struct {
}

func (t *TreeDTask) CanAccept(ids []harmonytask.TaskID, engine *harmonytask.TaskEngine) (*harmonytask.TaskID, error) {
if isDevnet {
return &ids[0], nil
}
if engine.Resources().Gpu > 0 {
return &ids[0], nil
}
Expand Down
6 changes: 5 additions & 1 deletion curiosrc/seal/task_treerc.go
Original file line number Diff line number Diff line change
Expand Up @@ -153,13 +153,17 @@ func (t *TreeRCTask) TypeDetails() harmonytask.TaskTypeDetails {
if isDevnet {
ssize = abi.SectorSize(2 << 20)
}
gpu := 1.0
if isDevnet {
gpu = 0
}

return harmonytask.TaskTypeDetails{
Max: t.max,
Name: "TreeRC",
Cost: resources.Resources{
Cpu: 1,
Gpu: 1,
Gpu: gpu,
Ram: 8 << 30,
Storage: t.sc.Storage(t.taskToSector, storiface.FTSealed, storiface.FTCache, ssize, storiface.PathSealing, paths.MinFreeStoragePercentage),
},
Expand Down

0 comments on commit 64686d9

Please sign in to comment.