mirror of
https://github.com/wassname/ray.git
synced 2026-07-28 11:25:04 +08: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:
@@ -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);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user