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)
mplot.mart: make isodensities more reliable e18d78f623ef5893a9ecf9cb7e6309de7df7352c I am 2022-04-13 06:18:50
misc: add get_isodistances() function ee82e4a69e51c6fa6a19e1715f71173907f9c4af I am 2022-04-13 06:16:05
testcases.testcases_2D: add natafm_plane_2D case 65f6f76b97f340123083369a9f705673e9e6eb30 I am 2022-04-12 21:38:36
qt_gui.qt_dicebox: add Razitko box tab, simplify setup widget e502adfa6458c63f18b81410c0a923aeee610641 I am 2022-04-11 05:41:07
dicebox: backport assess_candidates() to Chrt 62628b5b5f0f2da1f37c504175e4b7678ff94e8e I am 2022-04-11 05:39:40
dicebox.Goal: add chee and chee2 potentials 1b7e1af9932a9761652b57f2445daa7612f8f09e I am 2022-04-11 00:34:30
ghull.Ghull: fix NaN in get_r() method 654d4d32ebf8d14f88bc78dbee27567e9aa9564e I am 2022-04-10 16:06:24
estimation: nahradit zastaralou hlavičku 00b7aa07abc3072261da2cc7ba775d5228eefdf7 I am 2022-04-04 03:34:36
testcases.testcases_2D: add more nataf ceses ff4873afb1722500e3faed3c7a7f2552496b6e08 I am 2022-04-02 18:48:42
dicebox.Goal._handle_candidates: trigger cache update 80d401d5c4aaab0894d92e6df5390aff12738880 I am 2022-03-30 22:11:24
mplot.mfigs: add G_U_distortion plot 6ed034375dfd042706a91a368c9483270095e75c I am 2022-03-20 14:42:50
mplot.mart: add number_points function dab89bdb9e5190600aa394c9b65cfa24d162be0e I am 2022-03-20 14:42:23
testcases:testcases_nD: add hyperplane_pf3 87176287101b0a15a86c7999ba9626674400d225 I am 2022-03-20 14:41:26
testcases:gaussian_2D: add pf estimation for sinshilds case 889b5aebae164ea3fb1f9375ae58d1afa4687696 I am 2022-03-17 20:42:13
mplot: add rbf_density_plot() 62ce990cb9418418879d0f5e084a26043b5bfdeb I am 2022-03-04 03:00:32
misc: little changes to the rbf class 058a0401db09f4e9e68af72c987c3b879077864d I am 2022-03-03 22:53:48
mplot.maxes: rbf, one more try 8303470585507772e8170504989835f04a7828b9 I am 2022-03-02 22:13:08
mplot.maxes: add rbf_plot 3485da2191b2f64fac76813d072a6b6f6e2fba71 I am 2022-03-02 03:35:27
mplot.maxes: add rbf plot bd5055adced9e0d8887fa213baa0ff9f9e038ba4 I am 2022-03-02 02:17:18
misc: add small class for rbf surrogate model f8beecf63302ceae6d3462ed279b796b54149bdf I am 2022-03-02 02:16:01
Commit e18d78f623ef5893a9ecf9cb7e6309de7df7352c - mplot.mart: make isodensities more reliable
Author: I am
Author date (UTC): 2022-04-13 06:18
Committer name: I am
Committer date (UTC): 2022-04-13 06:18
Parent(s): ee82e4a69e51c6fa6a19e1715f71173907f9c4af
Signer:
Signing key:
Signing status: N
Tree: 580437daebc5d46acc645c3ab9f1f49c16a447c3
File Lines added Lines deleted
mplot/mart.py 16 22
mplot/maxes.py 6 3
File mplot/mart.py changed (mode: 100644) (index b7bc751..439531b)
... ... def rbf_colormesh(ax, ngrid=500, **kwargs):
437 437 return ax.pcolormesh(X, Y, C, cmap=cmap, shading='nearest', zorder=-100, rasterized=True, **kwargs) return ax.pcolormesh(X, Y, C, cmap=cmap, shading='nearest', zorder=-100, rasterized=True, **kwargs)
438 438
439 439
440
440 441 def gcircle(ax, r=1, nrod=200, **kwargs): def gcircle(ax, r=1, nrod=200, **kwargs):
441 442 if ax.space == 'G': if ax.space == 'G':
442 443 circle = mpatches.Circle((0,0), r, **kwargs) circle = mpatches.Circle((0,0), r, **kwargs)
443 444 else: else:
444 phi = np.linspace(0, 6.283185307, nrod, endpoint=True)
445 cos_phi = np.cos(phi)
446 sin_phi = np.sin(phi)
447
448 sample_G = np.array((cos_phi, sin_phi)).T * r
449
450 f_model = ax.sample_box.f_model
451 sample = f_model.new_sample(sample_G, space='G', extend=True)
445 sample = wmisc.get_isodistances(ax.sample_box.f_model, r, nrod=200)
452 446 xy = getattr(sample, ax.space)[:,:2] xy = getattr(sample, ax.space)[:,:2]
453 447 circle = mpatches.Polygon(xy, **kwargs) circle = mpatches.Polygon(xy, **kwargs)
454 448
 
... ... def uframe(ax, **kwargs):
465 459
466 460
467 461 def isocurves(ax, ngrid=200, limits=None, ncurves=5, **kwargs): def isocurves(ax, ngrid=200, limits=None, ncurves=5, **kwargs):
468 if limits is None:
469 #xmin, xmax = ax.get_xlim()
470 #ymin, ymax = ax.get_ylim()
462 r = ncurves + 1 #č jakási rezerva, mám už plné zuby s těmi limity
463 sample = wmisc.get_isodistances(ax.sample_box.f_model, r, nrod=ngrid)
464 xy = getattr(sample, ax.space)[:,:2]
471 465
472 sample_G = np.array([[-ncurves, -ncurves], [ncurves, ncurves]])
473 sample = ax.sample_box.f_model.new_sample(sample_G, space='G', extend=True)
474 xy = getattr(sample, ax.space)[:,:2]
475 xmin, ymin = np.min(xy, axis=0)
476 xmax, ymax = np.max(xy, axis=0)
466 xmin, ymin = np.min(xy, axis=0)
467 xmax, ymax = np.max(xy, axis=0)
477 468
478 else: # G-čko zlobí
479 xmin, xmax, ymin, ymax = limits
480
481
469 if limits is not None: # G-čko zlobí
470 lxmin, lxmax, lymin, lymax = limits
471 xmin = min(xmin, lxmin)
472 xmax = max(xmax, lxmax)
473 ymin = min(ymin, lymin)
474 ymax = max(ymax, lymax)
482 475
483 476 x = np.linspace(xmin, xmax, ngrid) x = np.linspace(xmin, xmax, ngrid)
484 477 y = np.linspace(ymin, ymax, ngrid) y = np.linspace(ymin, ymax, ngrid)
 
... ... def curly(ax, linewidths=[0.7, 0.5, 0.4, 0.3, 0.2, 0.1], nrid=200, color='k', **
557 550 if ax.space in ('U', 'aU'): if ax.space in ('U', 'aU'):
558 551 return None return None
559 552
560 elif (ax.sample_box.nvar==2) and (ax.space in ('Rn', 'aRn', 'R', 'aR', 'P', 'aP')):
561 isocurves(ax, ngrid=nrid, limits=None, ncurves=len(linewidths),\
553 elif (ax.sample_box.nvar == 2) and (ax.space in ('Rn', 'aRn', 'R', 'aR', 'P', 'aP')):
554 limits = (*ax.get_xlim(), *ax.get_ylim())
555 isocurves(ax, ngrid=nrid, limits=limits, ncurves=len(linewidths),\
562 556 linewidths=np.flip(linewidths), colors=[color], **kwargs) linewidths=np.flip(linewidths), colors=[color], **kwargs)
563 557
564 558 else: else:
File mplot/maxes.py changed (mode: 100644) (index 7cd68b1..288a7be)
... ... def tri_nodes_plot(ax, tri_space=None, tn_scheme=None, ms=3, mew=0.6, lw=0.7,
279 279 on_delete_simplex=None) on_delete_simplex=None)
280 280
281 281 mart.setup(ax) mart.setup(ax)
282 mart.curly(ax, nrid=nrid, linewidths=linewidths)
283 282 Tri.integrate() Tri.integrate()
284 283 if tri_space == ax.space: if tri_space == ax.space:
285 284 mart.triplot(ax, color="#B2B2B2", lw=lw/1.4, zorder=100) mart.triplot(ax, color="#B2B2B2", lw=lw/1.4, zorder=100)
 
... ... def tri_nodes_plot(ax, tri_space=None, tn_scheme=None, ms=3, mew=0.6, lw=0.7,
287 286 mart.tri_plot(ax, Tri=Tri, color="#B2B2B2", lw=lw/1.4, zorder=100, rasterized=True) mart.tri_plot(ax, Tri=Tri, color="#B2B2B2", lw=lw/1.4, zorder=100, rasterized=True)
288 287
289 288 mart.plot_points(ax, ms=ms, mew=mew, zorder=100500) mart.plot_points(ax, ms=ms, mew=mew, zorder=100500)
289 #č curly a boundaries raději nakreslíme co nejpozději
290 mart.curly(ax, nrid=nrid, linewidths=linewidths)
290 291 try: try:
291 292 mart.plot_boundaries(ax, lw=lw, zorder=1050, nrod=nrid) mart.plot_boundaries(ax, lw=lw, zorder=1050, nrod=nrid)
292 293 except: except:
 
... ... def tri_plot(ax, tri_space=None, linewidths=[0.7, 0.5, 0.4, 0.3, 0.2, 0.1],
317 318 on_delete_simplex=None) on_delete_simplex=None)
318 319
319 320 mart.setup(ax) mart.setup(ax)
320 mart.curly(ax, nrid=nrid, linewidths=linewidths)
321 321 if tri_space == ax.space: if tri_space == ax.space:
322 322 mart.triplot(ax, color="#B2B2B2", lw=lw/1.4, zorder=100) mart.triplot(ax, color="#B2B2B2", lw=lw/1.4, zorder=100)
323 323 else: else:
324 324 mart.tri_plot(ax, Tri=Tri, color="#B2B2B2", lw=lw/1.4, zorder=100, rasterized=True) mart.tri_plot(ax, Tri=Tri, color="#B2B2B2", lw=lw/1.4, zorder=100, rasterized=True)
325 325
326 326 mart.plot_points(ax, ms=ms, mew=mew, zorder=100500) mart.plot_points(ax, ms=ms, mew=mew, zorder=100500)
327 #č curly a boundaries raději nakreslíme co nejpozději
328 mart.curly(ax, nrid=nrid, linewidths=linewidths)
327 329 try: try:
328 330 mart.plot_boundaries(ax, lw=lw, zorder=1050, nrod=nrid) mart.plot_boundaries(ax, lw=lw, zorder=1050, nrod=nrid)
329 331 except: except:
 
... ... def convex_hull_plot(ax, tri_space=None, ms=3, mew=0.6, lw=0.7, nrid=200,
348 350 tri_space = ax.space tri_space = ax.space
349 351
350 352 mart.setup(ax) mart.setup(ax)
351 mart.curly(ax, nrid=nrid, linewidths=linewidths)
352 353 qhull = khull.QHull(ax.sample_box, space=tri_space, incremental=False) qhull = khull.QHull(ax.sample_box, space=tri_space, incremental=False)
353 354 mart.qhull_plot(ax, qhull, color="#B2B2B2", lw=lw, zorder=100) mart.qhull_plot(ax, qhull, color="#B2B2B2", lw=lw, zorder=100)
354 355 mart.plot_points(ax, ms=ms, mew=mew, zorder=100500) mart.plot_points(ax, ms=ms, mew=mew, zorder=100500)
356 #č curly a boundaries raději nakreslíme co nejpozději
357 mart.curly(ax, nrid=nrid, linewidths=linewidths)
355 358 try: try:
356 359 mart.plot_boundaries(ax, lw=lw, zorder=1050, nrod=nrid) mart.plot_boundaries(ax, lw=lw, zorder=1050, nrod=nrid)
357 360 except: except:
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