mirror of
https://github.com/vale981/ray
synced 2025-03-06 10:31:39 -05:00
Fix scheduling_resources comment errors (#12991)
* Fix scheduling_resources comment error * add part code Co-authored-by: 灵洵 <fengbin.ffb@antgroup.com>
This commit is contained in:
parent
038a50af52
commit
3fab93b61b
2 changed files with 3 additions and 4 deletions
|
@ -200,8 +200,8 @@ void ResourceSet::AddResourcesCapacityConstrained(const ResourceSet &other,
|
|||
const FractionalResourceQuantity &to_add_resource_capacity = resource_pair.second;
|
||||
if (total_resource_map.count(to_add_resource_label) != 0) {
|
||||
// If resource exists in total map, add to the local capacity map.
|
||||
// If the new capacity will be greater the total capacity, set the new capacity to
|
||||
// total capacity (capping to the total)
|
||||
// If the new capacity is less than the total capacity, set the new capacity to
|
||||
// the local capacity (capping to the total).
|
||||
const FractionalResourceQuantity &total_capacity =
|
||||
total_resource_map.at(to_add_resource_label);
|
||||
resource_capacity_[to_add_resource_label] =
|
||||
|
|
|
@ -136,8 +136,7 @@ class ResourceSet {
|
|||
///
|
||||
/// \param other: The other resource set to add.
|
||||
/// \param total_resources: Total resource set which sets upper limits on capacity for
|
||||
/// each label. \return True if the resource set was added successfully. False
|
||||
/// otherwise.
|
||||
/// each label.
|
||||
void AddResourcesCapacityConstrained(const ResourceSet &other,
|
||||
const ResourceSet &total_resources);
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue