Lookup returns the spec for a given GPU type and count.
(gpuType string, gpuCount int)
| 60 | |
| 61 | // Lookup returns the spec for a given GPU type and count. |
| 62 | func (s *SpecStore) Lookup(gpuType string, gpuCount int) *api.GpuSpecConfig { |
| 63 | spec, ok := s.specs[publicConfigKey(gpuType, gpuCount)] |
| 64 | if ok { |
| 65 | return &spec |
| 66 | } |
| 67 | return nil |
| 68 | } |
| 69 | |
| 70 | // IsSpecAvailable reports whether a concrete spec is available. Availability |
| 71 | // fails open when the API did not provide availability data. |