Skip to content

Commit

Permalink
add docstring
Browse files Browse the repository at this point in the history
  • Loading branch information
jduerholt committed Jul 6, 2023
1 parent cbe0d2b commit 0e71cdb
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion botorch/optim/parameter_constraints.py
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,10 @@ def _generate_unfixed_nonlin_constraints(
fixed_features: Dict[int, float],
dimension: int,
) -> Optional[List[Callable[[Tensor], Tensor]]]:
# If constraints is None or an empty list, then return itself
"""Given a dictionary of fixed features, returns a list of callables for
nonlinear inequality constraints expecting only a tensor with the non-fixed
features as input.
"""
if not constraints:
return constraints

Expand Down

0 comments on commit 0e71cdb

Please sign in to comment.