Skip to content

Commit

Permalink
Fix LHS on TSEMO (#129)
Browse files Browse the repository at this point in the history
  • Loading branch information
marcosfelt authored Apr 21, 2021
1 parent 6b846db commit fa785af
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions summit/strategies/tsemo.py
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ def suggest_experiments(self, num_experiments, prev_res: DataSet = None, **kwarg

# Suggest lhs initial design or append new experiments to previous experiments
if prev_res is None:
lhs = LHS(self.domain)
lhs = LHS(self.domain, categorical_method="descriptors")
self.iterations += 1
k = num_experiments if num_experiments > 1 else 2
return lhs.suggest_experiments(k, criterion="maximin")
Expand All @@ -173,9 +173,8 @@ def suggest_experiments(self, num_experiments, prev_res: DataSet = None, **kwarg
self.all_experiments = self.all_experiments.append(prev_res)

if self.all_experiments.shape[0] <= 3:
lhs = LHS(self.domain)
lhs = LHS(self.domain, categorical_method="descriptors")
self.iterations += 1
self.all_experiments = prev_res
return lhs.suggest_experiments(num_experiments)

# Get inputs (decision variables) and outputs (objectives)
Expand Down

0 comments on commit fa785af

Please sign in to comment.