MCPcopy Create free account
hub / github.com/Thunder-Compute/thunder-cli / getCurrentGPUCountCursorPosition

Method getCurrentGPUCountCursorPosition

tui/modify.go:511–520  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

509}
510
511func (m modifyModel) getCurrentGPUCountCursorPosition() int {
512 currentNumGPUs, _ := strconv.Atoi(m.currentInstance.NumGPUs)
513 gpuCounts := m.specs.GPUCounts(m.config.GPUType)
514 for i, count := range gpuCounts {
515 if count == currentNumGPUs {
516 return i
517 }
518 }
519 return 0
520}
521
522func (m modifyModel) getCurrentComputeCursorPosition() int {
523 currentVCPUs, _ := strconv.Atoi(m.currentInstance.CPUCores)

Callers 1

initModifyStepMethod · 0.95

Calls 1

GPUCountsMethod · 0.80

Tested by

no test coverage detected