Skip to content

Commit

Permalink
Merge pull request #195 from SURGroup/feature/remove_old_kriging_files
Browse files Browse the repository at this point in the history
Remove old kriging files
  • Loading branch information
dimtsap authored Jan 17, 2023
2 parents 1bfec7c + 32bdd29 commit e8eb6fe
Show file tree
Hide file tree
Showing 26 changed files with 114 additions and 1,017 deletions.
2 changes: 1 addition & 1 deletion src/UQpy/reliability/taylor_series/FORM.py
Original file line number Diff line number Diff line change
Expand Up @@ -312,7 +312,7 @@ def run(self, seed_x: Union[list, np.ndarray] = None,
else:
k = k + 1

self.logger.error("Error: %s", error_record[-1])
self.logger.info("Error: %s", error_record[-1])

if converged is True or k > self.n_iterations:
break
Expand Down
2 changes: 1 addition & 1 deletion src/UQpy/sampling/SimplexSampling.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ def __init__(
self,
nodes: Union[list, Numpy2DFloatArray] = None,
nsamples: PositiveInteger = None,
random_state: RandomStateType = None,
random_state: Union[RandomStateType, np.random.Generator] = None,
):
"""
Generate uniform random samples inside an n-dimensional simplex.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ def __init__(

self.random_state = random_state
if isinstance(self.random_state, int):
self.random_state = np.random.RandomState(self.random_state)
self.random_state = np.random.default_rng(self.random_state)
elif not isinstance(self.random_state, (type(None), np.random.RandomState)):
raise TypeError('UQpy: random_state must be None, an int or an np.random.Generator object.')
if self.random_state is None:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ def finalize(self, samples, samples_per_iteration):
def identify_bins(strata_metrics, points_to_add, random_state):
bins2break = np.array([])
points_left = points_to_add
while (np.where(strata_metrics == strata_metrics.max())[0].shape[0] < points_left):
while np.where(strata_metrics == strata_metrics.max())[0].shape[0] < points_left:
bin = np.where(strata_metrics == strata_metrics.max())[0]
bins2break = np.hstack([bins2break, bin])
strata_metrics[bin] = 0
Expand Down
1 change: 0 additions & 1 deletion src/UQpy/surrogates/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
from UQpy.surrogates.polynomial_chaos import *
from UQpy.surrogates.stochastic_reduced_order_models import *
from UQpy.surrogates.kriging import *
from UQpy.surrogates.gaussian_process import *
from UQpy.surrogates.baseclass import *

Expand Down
354 changes: 0 additions & 354 deletions src/UQpy/surrogates/kriging/Kriging.py

This file was deleted.

4 changes: 0 additions & 4 deletions src/UQpy/surrogates/kriging/__init__.py

This file was deleted.

28 changes: 0 additions & 28 deletions src/UQpy/surrogates/kriging/correlation_models/CubicCorrelation.py

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

7 changes: 0 additions & 7 deletions src/UQpy/surrogates/kriging/correlation_models/__init__.py

This file was deleted.

This file was deleted.

This file was deleted.

This file was deleted.

12 changes: 0 additions & 12 deletions src/UQpy/surrogates/kriging/regression_models/LinearRegression.py

This file was deleted.

This file was deleted.

4 changes: 0 additions & 4 deletions src/UQpy/surrogates/kriging/regression_models/__init__.py

This file was deleted.

This file was deleted.

This file was deleted.

4 changes: 2 additions & 2 deletions src/UQpy/utilities/MinimizeOptimizer.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,11 +24,11 @@ def optimize(self, function, initial_guess, args=(), jac=False):
return minimize(function, initial_guess, args=args,
method=self.method, bounds=self._bounds,
constraints=self.constraints, jac=jac,
options={'disp': True, 'maxiter': 10000, 'catol': 0.002})
options={'disp': False, 'maxiter': 10000, 'catol': 0.002})
else:
return minimize(function, initial_guess, args=args,
method=self.method, bounds=self._bounds, jac=jac,
options={'disp': True, 'maxiter': 10000, 'catol': 0.002})
options={'disp': False, 'maxiter': 10000, 'catol': 0.002})

def apply_constraints(self, constraints):
if self.method.lower() in ['cobyla', 'slsqp', 'trust-constr']:
Expand Down
Loading

0 comments on commit e8eb6fe

Please sign in to comment.