Skip to content

Commit

Permalink
Merge branch 'develop' into fides_exception_msg
Browse files Browse the repository at this point in the history
  • Loading branch information
PaulJonasJost authored Oct 25, 2023
2 parents 72e0e7b + 48019e2 commit 2d81189
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion pypesto/history/optimizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ def finalize(self, message: str = None, exitflag: int = None):
and not allclose(result[X], self.x_min)
):
# issue a warning, as if this happens, then something may be wrong
logger.warn(
logger.warning(
f"History has a better point {fval} than the current best "
"point {self.fval_min}."
)
Expand Down
8 changes: 4 additions & 4 deletions pypesto/optimize/optimizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -608,7 +608,7 @@ def get_default_options(self):
def check_x0_support(self, x_guesses: np.ndarray = None) -> bool:
"""Check whether optimizer supports x0."""
if x_guesses is not None and x_guesses.size > 0:
logger.warn("The Dlib optimizer does not support x0.")
logger.warning("The Dlib optimizer does not support x0.")
return False


Expand Down Expand Up @@ -666,7 +666,7 @@ def is_least_squares(self):
def check_x0_support(self, x_guesses: np.ndarray = None) -> bool:
"""Check whether optimizer supports x0."""
if x_guesses is not None and x_guesses.size > 0:
logger.warn("The pyswarm optimizer does not support x0.")
logger.warning("The pyswarm optimizer does not support x0.")
return False


Expand Down Expand Up @@ -940,7 +940,7 @@ def is_least_squares(self):
def check_x0_support(self, x_guesses: np.ndarray = None) -> bool:
"""Check whether optimizer supports x0."""
if x_guesses is not None and x_guesses.size > 0:
logger.warn("The pyswarms optimizer does not support x0.")
logger.warning("The pyswarms optimizer does not support x0.")
return False


Expand Down Expand Up @@ -1186,7 +1186,7 @@ def check_x0_support(self, x_guesses: np.ndarray = None) -> bool:
nlopt.GN_DIRECT_L_RAND_NOSCAL,
):
if x_guesses is not None and x_guesses.size > 0:
logger.warn(
logger.warning(
f"The NLopt optimizer method {self.method} does "
"not support x0."
)
Expand Down
4 changes: 4 additions & 0 deletions pypesto/profile/profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,10 @@ def create_next_guess(
for i_par in profile_index:
# only compute profiles for free parameters
if i_par in problem.x_fixed_indices:
# log a warning
logger.warning(
f"Parameter {i_par} is fixed and will not be profiled."
)
continue

current_profile = result.profile_result.get_profiler_result(
Expand Down

0 comments on commit 2d81189

Please sign in to comment.