iam-git / WellMet (public) (License: MIT) (since 2021-08-31) (hash sha1)
WellMet is pure Python framework for spatial structural reliability analysis. Or, more specifically, for "failure probability estimation and detection of failure surfaces by adaptive sequential decomposition of the design domain".
List of commits:
Subject Hash Author Date (UTC)
whitebox: add r exact for common nD boxes 7c4ab62f069f0efeb48a403dac5d27033003ded2 I am 2023-01-17 15:09:08
qt_gui: improve GRaph to show r-R bounds 59fa5bde7be2197b1f739bd1f829f927cef62603 I am 2023-01-17 14:26:16
dicebox.circumtri: calculate event's radia c6868cfbde7c8a86b73217da544f60e94a117bd8 I am 2023-01-16 06:12:34
simplex.Triangulation.get_averaged_mixed_normals: implement deep averaging 6dfb056e477479331c7a903ea52a98301fca4e71 I am 2023-01-15 23:26:43
replace flatten() by reshape(-1) everywhere. The former always allocates new array 97b35c989a5ad8e459bb60133222d50c7f78e1f0 I am 2023-01-15 12:04:30
qt_gui.qt_gui: explicitly export sample_box to console's namespace dd2e50245157082ddb645b693a8a8c573215d50c I am 2023-01-15 11:42:01
replace everywhere np.bool by just bool (it looks like newer numpy dropped it) ac208f89bbf0ad76d38790686041ea778a9b6376 I am 2023-01-15 11:31:56
simplex._Triangulation: implement averaged gradients() f6608597cf490dd6cf1a6af3b7d8e6d0a72732d9 I am 2023-01-15 09:37:14
add line and two lines problems for sensitivity analysis 0c620f7960399ed8b34e02d663772d0eb34e66f1 I am 2023-01-14 08:30:56
simplex.FullCubatureIntegration.get_sensitivities: do not normalize global gradient c648c484a5599a00236ab70c36cdf407c24f5306 I am 2023-01-14 04:51:16
simplex: implement sensitivities 65056319c51fd93deb76ce14e52c08869dfc04a2 I am 2023-01-13 11:27:46
mplot.maxes: prepare GRaph plot 68774535915af3deaf6104a0bbe9b3c4d24c0cec I am 2023-01-12 02:43:20
mplot.mgraph.tri_estimation_plot: use planar vertex estimator 1d300fa56248be9cdab5a4e5b0d4372f68fd5255 I am 2023-01-11 15:48:28
mplot.mart: implement lsf_boundary() contouring 8642d2f0c043f4e71af1cc45b9e25da326afd3ca I am 2023-01-11 05:20:00
mplot.mart.setup_labels: make labels more adaptive 60cd0b34a67b38df1c730dddc9e0771139818f33 I am 2023-01-11 04:35:47
simplex._SamplingTriangulation: self reference fix 79204ff15cba7c5ca24bb5b48e2073058acf00ae I am 2023-01-11 03:21:34
testcases.testcases_2D: add pf for rastrigin 4f3b35fe18496fcb9f59860174c876cb7a82749a I am 2023-01-10 23:39:45
dicebox.circumtri: fix initialization on ED loading. Use simple potential for space filling c02656e588a164685c4a750ce865c4b50f716563 I am 2023-01-10 23:37:30
simplex.FullCubatureIntegration.get_failure_moments: negative probabilities fix 27dd6bb1e5bb0eb1e28eef88e28913d1eca461da I am 2023-01-10 20:16:09
add more nD problems from literature 2380cdbdcf17dd5e0af19506c6f7bb1e838de03b I am 2023-01-10 06:13:56
Commit 7c4ab62f069f0efeb48a403dac5d27033003ded2 - whitebox: add r exact for common nD boxes
Author: I am
Author date (UTC): 2023-01-17 15:09
Committer name: I am
Committer date (UTC): 2023-01-17 15:09
Parent(s): 59fa5bde7be2197b1f739bd1f829f927cef62603
Signer:
Signing key:
Signing status: N
Tree: ed703985591141e339def6273074678a81b75460
File Lines added Lines deleted
wellmet/testcases/testcases_nD_papers.py 2 0
wellmet/whitebox.py 13 4
File wellmet/testcases/testcases_nD_papers.py changed (mode: 100644) (index f23dda7..381acb7)
... ... def passive_vehicle_suspension_3D():
141 141 #č 0.000525 je hodně dobrý odhad #č 0.000525 je hodně dobrý odhad
142 142 wt.pf_exact_method = 'FORM-based precise geometry analysis' wt.pf_exact_method = 'FORM-based precise geometry analysis'
143 143
144 wt.r_exact = (mu2 - DP1) / s
145
144 146 #wt.pf_exact = 0.00052 #wt.pf_exact = 0.00052
145 147 #wt.pf_exact_method = 'IS' #wt.pf_exact_method = 'IS'
146 148 #wt.Nsim = 1000000 #wt.Nsim = 1000000
File wellmet/whitebox.py changed (mode: 100644) (index 9b87bb9..4b3c7d9)
... ... class HyperPlane(WhiteBox): # куда ж без него...
280 280 self.beta_exact = betas[-1]/np.sqrt(np.sum(np.array(betas[:-1])**2)) self.beta_exact = betas[-1]/np.sqrt(np.sum(np.array(betas[:-1])**2))
281 281 self.pf_exact = stats.norm.cdf(-self.beta_exact) self.pf_exact = stats.norm.cdf(-self.beta_exact)
282 282 self.pf_exact_method = 'FORM (exact solution)' # Ang, Tang and Pythagoras self.pf_exact_method = 'FORM (exact solution)' # Ang, Tang and Pythagoras
283 self.r_exact = self.beta_exact
283 284
284 285
285 286 def __str__(wt): def __str__(wt):
 
... ... class Line(WhiteBox):
305 306
306 307 self.pf_exact = stats.norm.cdf(-beta) self.pf_exact = stats.norm.cdf(-beta)
307 308 self.pf_exact_method = 'FORM (exact solution)' # Ang, Tang and Pythagoras self.pf_exact_method = 'FORM (exact solution)' # Ang, Tang and Pythagoras
308
309 self.r_exact = self.beta_exact
309 310
310 311 def __str__(wt): def __str__(wt):
311 312 return 'Line%sD' % wt.f.nvar return 'Line%sD' % wt.f.nvar
 
... ... class TwoLine(WhiteBox):
329 330
330 331 self.pf_exact = stats.norm.cdf(-beta) * 2 self.pf_exact = stats.norm.cdf(-beta) * 2
331 332 self.pf_exact_method = '2FORM (exact solution)' # Ang, Tang and Pythagoras self.pf_exact_method = '2FORM (exact solution)' # Ang, Tang and Pythagoras
333 self.r_exact = self.beta
332 334
333 335
334 336 def __str__(wt): def __str__(wt):
 
... ... class Gaussian_Z_sum(WhiteBox): #ё куда ж без этого...
351 353 self.beta_exact = beta_exact self.beta_exact = beta_exact
352 354 self.pf_exact = stats.norm.cdf(-self.beta_exact) self.pf_exact = stats.norm.cdf(-self.beta_exact)
353 355 self.pf_exact_method = 'FORM (exact solution)' # Ang, Tang and Pythagoras self.pf_exact_method = 'FORM (exact solution)' # Ang, Tang and Pythagoras
356 self.r_exact = self.beta_exact
354 357
355 358
356 359 def __str__(wt): def __str__(wt):
 
... ... class Gaussian_Z_prod_2D(WhiteBox):
412 415 else: else:
413 416 self.pf_exact = 1 - gauss_prod_CDF(-self.const) self.pf_exact = 1 - gauss_prod_CDF(-self.const)
414 417 self.pf_exact_method = 'exact (Bessel) solution' self.pf_exact_method = 'exact (Bessel) solution'
415
418 self.r_exact = np.sqrt(np.abs(self.const) * 2)
416 419
417 420 def __str__(wt): def __str__(wt):
418 421 return 'Gaussian_Z_prod_2D' return 'Gaussian_Z_prod_2D'
 
... ... class Gaussian_ProdFourBetas_2D(WhiteBox):
448 451 BesselK1 = special.kn(1, const) BesselK1 = special.kn(1, const)
449 452 self.pf_exact = 1 - const * (StruveL1 * BesselK0 + StruveL0 * BesselK1 + 2/np.pi * BesselK0) self.pf_exact = 1 - const * (StruveL1 * BesselK0 + StruveL0 * BesselK1 + 2/np.pi * BesselK0)
450 453 self.pf_exact_method = 'exact (Bessel) solution' self.pf_exact_method = 'exact (Bessel) solution'
451
454 self.r_exact = self.beta
452 455
453 456 def __str__(wt): def __str__(wt):
454 457 return 'Gaussian_ProdFourBetas_2D' return 'Gaussian_ProdFourBetas_2D'
 
... ... class Lognormal_Z_prod(WhiteBox): #č ověřím to moje odvození...
472 475 self.beta_exact = beta_exact self.beta_exact = beta_exact
473 476 self.pf_exact = stats.norm.cdf(-self.beta_exact) self.pf_exact = stats.norm.cdf(-self.beta_exact)
474 477 self.pf_exact_method = 'FORM (exact solution)' # Ang, Tang and Pythagoras self.pf_exact_method = 'FORM (exact solution)' # Ang, Tang and Pythagoras
475
478 self.r_exact = self.beta_exact
476 479
477 480 def __str__(wt): def __str__(wt):
478 481 return 'Lognormal_Z_prod%sD'%(wt.f.nvar) return 'Lognormal_Z_prod%sD'%(wt.f.nvar)
 
... ... class Gaussian_Z_min(WhiteBox):
499 502 self.pf_exact = float(1 - mpmath.ncdf(self.const)**ndim) self.pf_exact = float(1 - mpmath.ncdf(self.const)**ndim)
500 503 else: else:
501 504 raise ValueError raise ValueError
505 self.r_exact = self.const
502 506 self.gm = g_models.Z_min(self.const) # min(X1, X2, XN) + const self.gm = g_models.Z_min(self.const) # min(X1, X2, XN) + const
503 507 # na začatku nemáme vzorky - pouze rozdělení a podpís # na začatku nemáme vzorky - pouze rozdělení a podpís
504 508 self.sample_box = SampleBox(self.f(), gm_signature=self.gm_signature) self.sample_box = SampleBox(self.f(), gm_signature=self.gm_signature)
 
... ... class Weibull_Z_min(WhiteBox):
545 549 self.pf_exact = 1e-4 self.pf_exact = 1e-4
546 550 self.const = -self.rvweibmin.ppf(self.pf_exact) self.const = -self.rvweibmin.ppf(self.pf_exact)
547 551
552 sf = 1 - mpmath.root(1 - mpmath.mpf(self.pf_exact), len(wb_scales))
553 self.r_exact = stats.norm.isf(float(sf))
548 554 self.gm = g_models.Z_min(self.const) self.gm = g_models.Z_min(self.const)
549 555 # na začatku nemáme vzorky - pouze rozdělení a podpís # na začatku nemáme vzorky - pouze rozdělení a podpís
550 556 self.sample_box = SampleBox(self.f(), gm_signature=self.gm_signature) self.sample_box = SampleBox(self.f(), gm_signature=self.gm_signature)
 
... ... class Gaussian_Z_max(WhiteBox):
574 580 self.pf_exact = float(mpmath.ncdf(-self.const)**ndim) self.pf_exact = float(mpmath.ncdf(-self.const)**ndim)
575 581 else: else:
576 582 raise ValueError raise ValueError
583 self.r_exact = np.sqrt(self.const**2 * ndim)
577 584 self.gm = g_models.Z_max(self.const) # min(X1, X2, XN) + const self.gm = g_models.Z_max(self.const) # min(X1, X2, XN) + const
578 585 # na začatku nemáme vzorky - pouze rozdělení a podpís # na začatku nemáme vzorky - pouze rozdělení a podpís
579 586 self.sample_box = SampleBox(self.f(), gm_signature=self.gm_signature) self.sample_box = SampleBox(self.f(), gm_signature=self.gm_signature)
 
... ... class SNorm_Z_sumsq(WhiteBox):
686 693
687 694
688 695 self.const = self.C self.const = self.C
696 self.R_exact = np.sqrt(self.const)
689 697 self.gm = g_models.Z_sumsq(self.C) self.gm = g_models.Z_sumsq(self.C)
690 698 # na začatku nemáme vzorky - pouze rozdělení a podpís # na začatku nemáme vzorky - pouze rozdělení a podpís
691 699 self.sample_box = SampleBox(self.f(), gm_signature=self.gm_signature) self.sample_box = SampleBox(self.f(), gm_signature=self.gm_signature)
 
... ... class SNorm_S_ball(WhiteBox):
743 751
744 752
745 753 self.r = r self.r = r
754 self.r_exact = self.r
746 755 self.gm = g_models.S_ball(r) self.gm = g_models.S_ball(r)
747 756 # na začatku nemáme vzorky - pouze rozdělení a podpís # na začatku nemáme vzorky - pouze rozdělení a podpís
748 757 self.sample_box = SampleBox(self.f(), gm_signature=self.gm_signature) self.sample_box = SampleBox(self.f(), gm_signature=self.gm_signature)
Hints:
Before first commit, do not forget to setup your git environment:
git config --global user.name "your_name_here"
git config --global user.email "your@email_here"

Clone this repository using HTTP(S):
git clone https://rocketgit.com/user/iam-git/WellMet

Clone this repository using ssh (do not forget to upload a key first):
git clone ssh://rocketgit@ssh.rocketgit.com/user/iam-git/WellMet

Clone this repository using git:
git clone git://git.rocketgit.com/user/iam-git/WellMet

You are allowed to anonymously push to this repository.
This means that your pushed commits will automatically be transformed into a merge request:
... clone the repository ...
... make some changes and some commits ...
git push origin main