pymordemos package¶
Submodules¶
analyze_pickle module¶
Analyze pickled data demo.
- Usage:
- analyze_pickle.py histogram [–detailed=DETAILED_DATA] [–error-norm=NORM] REDUCED_DATA SAMPLES analyze_pickle.py convergence [–detailed=DETAILED_DATA] [–error-norm=NORM] [–ndim=NDIM] REDUCED_DATA SAMPLES analyze_pickle.py (-h | –help)
This demo loads a pickled reduced discretization, solves for random parameters, estimates the reduction errors and then visualizes these estimates. If the detailed discretization and the reductor are also provided, the estimated error is visualized in comparison to the real reduction error.
The needed data files are created by the thermal block demo, by setting the ‘–pickle’ option.
- Arguments:
REDUCED_DATA File containing the pickled reduced discretization.
SAMPLES Number of parameter samples to test with.
- Options:
--detailed=DETAILED_DATA File containing the high-dimensional discretization and the reductor. --error-norm=NORM Name of norm in which to compute the errors. --ndim=NDIM Number of reduced basis dimensions for which to estimate the error.
burgers module¶
Burgers demo.
Solves a two-dimensional Burgers-type equation. See pymor.analyticalproblems.burgers for more details.
- Usage:
- burgers.py [-hp] [–grid=NI] [–grid-type=TYPE] [–initial-data=TYPE] [–lxf-lambda=VALUE] [–nt=COUNT]
- [–not-periodic] [–num-flux=FLUX] [–vx=XSPEED] [–vy=YSPEED] EXP
- Arguments:
- EXP Exponent
- Options:
--grid=NI Use grid with (2*NI)*NI elements [default: 60]. --grid-type=TYPE Type of grid to use (rect, tria) [default: rect]. --initial-data=TYPE Select the initial data (sin, bump) [default: sin] --lxf-lambda=VALUE Parameter lambda in Lax-Friedrichs flux [default: 1]. --nt=COUNT Number of time steps [default: 100]. --not-periodic Solve with dirichlet boundary conditions on left and bottom boundary. --num-flux=FLUX Numerical flux to use (lax_friedrichs, engquist_osher) [default: lax_friedrichs]. -h, --help Show this message. --vx=XSPEED Speed in x-direction [default: 1]. --vy=YSPEED Speed in y-direction [default: 1].
burgers_ei module¶
Burgers with EI demo.
Model order reduction of a two-dimensional Burgers-type equation (see pymor.analyticalproblems.burgers) using the reduced basis method with empirical operator interpolation.
- Usage:
- burgers_ei.py [options] EXP_MIN EXP_MAX EI_SNAPSHOTS EISIZE SNAPSHOTS RBSIZE
- Arguments:
EXP_MIN Minimal exponent
EXP_MAX Maximal exponent
EI_SNAPSHOTS Number of snapshots for empirical interpolation.
EISIZE Number of interpolation DOFs.
SNAPSHOTS Number of snapshots for basis generation.
RBSIZE Size of the reduced basis
- Options:
--cache-region=REGION Name of cache region to use for caching solution snapshots (NONE, MEMORY, DISK, PERSISTENT) [default: DISK] --grid=NI Use grid with (2*NI)*NI elements [default: 60]. --grid-type=TYPE Type of grid to use (rect, tria) [default: rect]. --initial-data=TYPE Select the initial data (sin, bump) [default: sin] --lxf-lambda=VALUE Parameter lambda in Lax-Friedrichs flux [default: 1]. --not-periodic Solve with dirichlet boundary conditions on left and bottom boundary. --nt=COUNT Number of time steps [default: 100]. --num-flux=FLUX Numerical flux to use (lax_friedrichs, engquist_osher) [default: lax_friedrichs]. -h, --help Show this message. -p, --plot-err Plot error. --plot-ei-err Plot empirical interpolation error. --plot-error-landscape Calculate and show plot of reduction error vs. basis sizes. --plot-error-landscape-N=COUNT Number of basis sizes to test [default: 10] --plot-error-landscape-M=COUNT Number of collateral basis sizes to test [default: 10] --plot-solutions Plot some example solutions. --test=COUNT Use COUNT snapshots for stochastic error estimation [default: 10]. --vx=XSPEED Speed in x-direction [default: 1]. --vy=YSPEED Speed in y-direction [default: 1]. --ipython-engines=COUNT If positive, the number of IPython cluster engines to use for parallel greedy search. If zero, no parallelization is performed. [default: 0] --ipython-profile=PROFILE IPython profile to use for parallelization.
elliptic module¶
Simple demonstration of solving the Poisson equation in 2D using pyMOR’s builtin discretizations.
- Usage:
- elliptic.py [–fv] [–rect] PROBLEM-NUMBER DIRICHLET-NUMBER NEUMANN-NUMBER NEUMANN-COUNT
- Arguments:
PROBLEM-NUMBER {0,1}, selects the problem to solve
DIRICHLET-NUMBER {0,1,2}, selects the Dirichlet data function
NEUMANN-NUMBER {0,1}, selects the Neumann data function
- NEUMANN-COUNT 0: no neumann boundary
- 1: right edge is neumann boundary 2: right+top edges are neumann boundary 3: right+top+bottom edges are neumann boundary
- Options:
-h, --help Show this message. --fv Use finite volume discretization instead of finite elements. --rect Use RectGrid instead of TriaGrid.
elliptic2 module¶
Simple demonstration of solving the Poisson equation in 2D using pyMOR’s builtin discretizations.
- Usage:
- elliptic2.py [–fv] PROBLEM-NUMBER N
- Arguments:
PROBLEM-NUMBER {0,1}, selects the problem to solve
N Triangle count per direction
- Options:
-h, --help Show this message. --fv Use finite volume discretization instead of finite elements.
elliptic_oned module¶
Proof of concept for solving the Poisson equation in 1D using linear finite elements and our grid interface
- Usage:
- elliptic_oned.py [–fv] PROBLEM-NUMBER N
- Arguments:
PROBLEM-NUMBER {0,1}, selects the problem to solve
N Grid interval count
- Options:
-h, --help Show this message. --fv Use finite volume discretization instead of finite elements.
elliptic_unstructured module¶
Simple demonstration of solving the Poisson equation in 2D on a circular sector domain of radius 1 using an unstructured mesh.
Note that Gmsh (http://geuz.org/gmsh/) is required for meshing.
- Usage:
- elliptic_unstructured.py [–fv] ANGLE NUM_POINTS CLSCALE
- Arguments:
ANGLE The angle of the circular sector.
NUM_POINTS The number of points that form the arc of the circular sector.
CLSCALE Mesh element size scaling factor.
- Options:
-h, --help Show this message. --fv Use finite volume discretization instead of finite elements.
parabolic module¶
Simple demonstration of solving parabolic equations using pyMOR’s builtin discretization toolkit.
- Usage:
- parabolic.py [options] heat TOP parabolic.py [options] dar SPEED
- Arguments:
- TOP The heat diffusion coefficient for the top bars. SPEED The advection speed.
- Options:
-h, --help Show this message. --fv Use finite volume discretization instead of finite elements. --rect Use RectGrid instead of TriaGrid. --grid=NI Use grid with NIxNI intervals [default: 100]. --nt=COUNT Number of time steps [default: 100].
parabolic_mor module¶
Reduced basis approximation of the heat equation.
- Usage:
- parabolic_mor.py [options] BACKEND ALG SNAPSHOTS RBSIZE TEST
- Arguments:
BACKEND Discretization toolkit to use (pymor, fenics).
- ALG The model reduction algorithm to use
- (greedy, adaptive_greedy, pod).
- SNAPSHOTS greedy/pod: number of training set parameters
- adaptive_greedy: size of validation set.
RBSIZE Size of the reduced basis.
TEST Number of test parameters for reduction error estimation.
thermalblock module¶
Thermalblock demo.
- Usage:
- thermalblock.py [options] XBLOCKS YBLOCKS SNAPSHOTS RBSIZE thermalblock.py -h | –help
- Arguments:
XBLOCKS Number of blocks in x direction.
YBLOCKS Number of blocks in y direction.
SNAPSHOTS naive: ignored
- greedy/pod: Number of training_set parameters per block
- (in total SNAPSHOTS^(XBLOCKS * YBLOCKS) parameters).
adaptive_greedy: size of validation set.
RBSIZE Size of the reduced basis
- Options:
--adaptive-greedy-rho=RHO See pymor.algorithms.adaptivegreedy [default: 1.1]. --adaptive-greedy-gamma=GAMMA See pymor.algorithms.adaptivegreedy [default: 0.2]. --adaptive-greedy-theta=THETA See pymor.algorithms.adaptivegreedy [default: 0.] --alg=ALG The model reduction algorithm to use (naive, greedy, adaptive_greedy, pod) [default: greedy]. --cache-region=REGION Name of cache region to use for caching solution snapshots (none, memory, disk, persistent) [default: none]. --extension-alg=ALG Basis extension algorithm (trivial, gram_schmidt) to be used [default: gram_schmidt]. --fenics Use FEniCS discretization. --grid=NI Use grid with 4*NI*NI elements [default: 100]. -h, --help Show this message. --ipython-engines=COUNT If positive, the number of IPython cluster engines to use for parallel greedy search. If zero, no parallelization is performed. [default: 0] --ipython-profile=PROFILE IPython profile to use for parallelization. --list-vector-array Solve using ListVectorArray[NumpyVector] instead of NumpyVectorArray. --order=ORDER Polynomial order of the Lagrange finite elements to use in FEniCS discretization [default: 1]. --pickle=PREFIX Pickle reduced discretizaion, as well as reductor and high-dimensional discretization to files with this prefix. --plot-err Plot error. --plot-solutions Plot some example solutions. --plot-error-sequence Plot reduction error vs. basis size. --product=PROD Product (euclidean, h1) w.r.t. which to orthonormalize and calculate Riesz representatives [default: h1]. --reductor=RED Reductor (error estimator) to choose (traditional, residual_basis) [default: residual_basis] --test=COUNT Use COUNT snapshots for stochastic error estimation [default: 10]. --greedy-without-estimator Do not use error estimator for basis generation.
-
pymordemos.thermalblock.
discretize_fenics
(xblocks, yblocks, grid_num_intervals, element_order)[source]¶
-
pymordemos.thermalblock.
discretize_pymor
(xblocks, yblocks, grid_num_intervals, use_list_vector_array)[source]¶
-
pymordemos.thermalblock.
reduce_adaptive_greedy
(d, reductor, validation_mus, extension_alg_name, max_extensions, use_estimator, rho, gamma, theta, pool)[source]¶
-
pymordemos.thermalblock.
reduce_greedy
(d, reductor, snapshots_per_block, extension_alg_name, max_extensions, use_estimator, pool)[source]¶
thermalblock_adaptive module¶
Modified thermalblock demo using adaptive greedy basis generation algorithm.
- Usage:
- thermalblock_adaptive.py [options] RBSIZE thermalblock_adaptive.py -h | –help
- Arguments:
- RBSIZE Size of the reduced basis
- Options:
-h, --help Show this message. --without-estimator Do not use error estimator for basis generation. --extension-alg=ALG Basis extension algorithm (trivial, gram_schmidt) to be used [default: gram_schmidt]. --grid=NI Use grid with 2*NI*NI elements [default: 100]. --pickle=PREFIX Pickle reduced discretizaion, as well as reductor and high-dimensional discretization to files with this prefix. -p, --plot-err Plot error. --plot-solutions Plot some example solutions. --plot-error-sequence Plot reduction error vs. basis size. --product=PROD Product (euclidean, h1) w.r.t. which to orthonormalize and calculate Riesz representatives [default: h1]. --reductor=RED Reductor (error estimator) to choose (traditional, residual_basis) [default: residual_basis] --test=COUNT Use COUNT snapshots for stochastic error estimation [default: 10]. --ipython-engines=COUNT If positive, the number of IPython cluster engines to use for parallel greedy search. If zero, no parallelization is performed. [default: 0] --ipython-profile=PROFILE IPython profile to use for parallelization. --cache-region=REGION Name of cache region to use for caching solution snapshots (NONE, MEMORY, DISK, PERSISTENT) [default: NONE] --list-vector-array Solve using ListVectorArray[NumpyVector] instead of NumpyVectorArray. --visualize-refinement Visualize the training set refinement indicators. --validation-mus Size of validation set. [default: 0] --rho=VALUE Maximum allowed ratio between error on validation set and on training set [default: 1.1]. --gamma=VALUE Weight factor for age penalty term in refinement indicators [default: 0.2]. --theta=VALUE Ratio of elements to refine [default: 0.].
thermalblock_gui module¶
Thermalblock with GUI demo
- Usage:
- thermalblock_gui.py [-h] [–product=PROD] [–grid=NI] [–testing]
- [–help] XBLOCKS YBLOCKS SNAPSHOTS RBSIZE
- Arguments:
XBLOCKS Number of blocks in x direction.
YBLOCKS Number of blocks in y direction.
- SNAPSHOTS Number of snapshots for basis generation per component.
- In total SNAPSHOTS^(XBLOCKS * YBLOCKS).
RBSIZE Size of the reduced basis
- Options:
--grid=NI Use grid with 2*NI*NI elements [default: 60]. --product=PROD Product (euclidean, h1) w.r.t. which to orthonormalize and calculate Riesz representatives [default: h1]. --testing load the gui and exit right away (for functional testing) -h, --help Show this message.
-
class
pymordemos.thermalblock_gui.
AllPanel
(parent, reduced_sim, detailed_sim)[source]¶ Bases:
PySide.QtGui.QWidget
Methods
QWidget
acceptDrops
,accessibleDescription
,accessibleName
,actionEvent
,actions
,activateWindow
,addAction
,addActions
,adjustSize
,autoFillBackground
,backgroundRole
,baseSize
,changeEvent
,childAt
,childrenRect
,childrenRegion
,clearFocus
,clearMask
,close
,closeEvent
,contentsMargins
,contentsRect
,contextMenuEvent
,contextMenuPolicy
,createWinId
,cursor
,destroy
,devType
,dragEnterEvent
,dragLeaveEvent
,dragMoveEvent
,dropEvent
,effectiveWinId
,ensurePolished
,enterEvent
,event
,focusInEvent
,focusNextChild
,focusNextPrevChild
,focusOutEvent
,focusPolicy
,focusPreviousChild
,focusProxy
,focusWidget
,font
,fontInfo
,fontMetrics
,foregroundRole
,frameGeometry
,frameSize
,geometry
,getContentsMargins
,grabGesture
,grabKeyboard
,grabMouse
,grabShortcut
,graphicsEffect
,graphicsProxyWidget
,hasFocus
,hasMouseTracking
,height
,heightForWidth
,hide
,hideEvent
,inputContext
,inputMethodEvent
,inputMethodHints
,inputMethodQuery
,insertAction
,insertActions
,isActiveWindow
,isAncestorOf
,isEnabled
,isEnabledTo
,isFullScreen
,isHidden
,isLeftToRight
,isMaximized
,isMinimized
,isModal
,isRightToLeft
,isVisible
,isVisibleTo
,isWindow
,isWindowModified
,keyboardGrabber
,keyPressEvent
,keyReleaseEvent
,languageChange
,layout
,layoutDirection
,leaveEvent
,locale
,lower
,mapFrom
,mapFromGlobal
,mapFromParent
,mapTo
,mapToGlobal
,mapToParent
,mask
,maximumHeight
,maximumSize
,maximumWidth
,metric
,minimumHeight
,minimumSize
,minimumSizeHint
,minimumWidth
,mouseDoubleClickEvent
,mouseGrabber
,mouseMoveEvent
,mousePressEvent
,mouseReleaseEvent
,move
,moveEvent
,nativeParentWidget
,nextInFocusChain
,normalGeometry
,overrideWindowFlags
,overrideWindowState
,paintEngine
,paintEvent
,palette
,parentWidget
,pos
,previousInFocusChain
,raise_
,rect
,releaseKeyboard
,releaseMouse
,releaseShortcut
,removeAction
,render
,repaint
,resetInputContext
,resize
,resizeEvent
,restoreGeometry
,saveGeometry
,scroll
,setAcceptDrops
,setAccessibleDescription
,setAccessibleName
,setAttribute
,setAutoFillBackground
,setBackgroundRole
,setBaseSize
,setContentsMargins
,setContextMenuPolicy
,setCursor
,setDisabled
,setEnabled
,setFixedHeight
,setFixedSize
,setFixedWidth
,setFocus
,setFocusPolicy
,setFocusProxy
,setFont
,setForegroundRole
,setGeometry
,setGraphicsEffect
,setHidden
,setInputContext
,setInputMethodHints
,setLayout
,setLayoutDirection
,setLocale
,setMask
,setMaximumHeight
,setMaximumSize
,setMaximumWidth
,setMinimumHeight
,setMinimumSize
,setMinimumWidth
,setMouseTracking
,setPalette
,setParent
,setShortcutAutoRepeat
,setShortcutEnabled
,setSizeIncrement
,setSizePolicy
,setStatusTip
,setStyle
,setStyleSheet
,setTabOrder
,setToolTip
,setUpdatesEnabled
,setVisible
,setWhatsThis
,setWindowFilePath
,setWindowFlags
,setWindowIcon
,setWindowIconText
,setWindowModality
,setWindowModified
,setWindowOpacity
,setWindowRole
,setWindowState
,setWindowTitle
,show
,showEvent
,showFullScreen
,showMaximized
,showMinimized
,showNormal
,size
,sizeHint
,sizeIncrement
,sizePolicy
,stackUnder
,statusTip
,style
,styleSheet
,tabletEvent
,testAttribute
,toolTip
,underMouse
,ungrabGesture
,unsetCursor
,unsetLayoutDirection
,unsetLocale
,update
,updateGeometry
,updateMicroFocus
,updatesEnabled
,visibleRegion
,whatsThis
,wheelEvent
,width
,window
,windowFilePath
,windowFlags
,windowIcon
,windowIconText
,windowModality
,windowOpacity
,windowRole
,windowState
,windowTitle
,windowType
,winId
,x
,x11Info
,x11PictureHandle
,y
,__new__
QObject
blockSignals
,childEvent
,children
,connect
,connectNotify
,customEvent
,deleteLater
,disconnect
,disconnectNotify
,dumpObjectInfo
,dumpObjectTree
,dynamicPropertyNames
,emit
,eventFilter
,findChild
,findChildren
,inherits
,installEventFilter
,isWidgetType
,killTimer
,metaObject
,moveToThread
,objectName
,parent
,property
,receivers
,registerUserData
,removeEventFilter
,sender
,senderSignalIndex
,setObjectName
,setProperty
,signalsBlocked
,startTimer
,thread
,timerEvent
,tr
,trUtf8
QPaintDevice
colorCount
,depth
,heightMM
,logicalDpiX
,logicalDpiY
,numColors
,paintingActive
,physicalDpiX
,physicalDpiY
,widthMM
Attributes
AllPanel
staticMetaObject
QWidget
customContextMenuRequested
,DrawChildren
,DrawWindowBackground
,IgnoreMask
,RenderFlag
,RenderFlags
QObject
destroyed
QPaintDevice
PaintDeviceMetric
,painters
,PdmDepth
,PdmDpiX
,PdmDpiY
,PdmHeight
,PdmHeightMM
,PdmNumColors
,PdmPhysicalDpiX
,PdmPhysicalDpiY
,PdmWidth
,PdmWidthMM
-
class
pymordemos.thermalblock_gui.
DetailedSim
(args)[source]¶ Bases:
pymordemos.thermalblock_gui.SimBase
Methods
DetailedSim
solve
-
class
pymordemos.thermalblock_gui.
ParamRuler
(parent, sim)[source]¶ Bases:
PySide.QtGui.QWidget
Methods
ParamRuler
enable
QWidget
acceptDrops
,accessibleDescription
,accessibleName
,actionEvent
,actions
,activateWindow
,addAction
,addActions
,adjustSize
,autoFillBackground
,backgroundRole
,baseSize
,changeEvent
,childAt
,childrenRect
,childrenRegion
,clearFocus
,clearMask
,close
,closeEvent
,contentsMargins
,contentsRect
,contextMenuEvent
,contextMenuPolicy
,createWinId
,cursor
,destroy
,devType
,dragEnterEvent
,dragLeaveEvent
,dragMoveEvent
,dropEvent
,effectiveWinId
,ensurePolished
,enterEvent
,event
,focusInEvent
,focusNextChild
,focusNextPrevChild
,focusOutEvent
,focusPolicy
,focusPreviousChild
,focusProxy
,focusWidget
,font
,fontInfo
,fontMetrics
,foregroundRole
,frameGeometry
,frameSize
,geometry
,getContentsMargins
,grabGesture
,grabKeyboard
,grabMouse
,grabShortcut
,graphicsEffect
,graphicsProxyWidget
,hasFocus
,hasMouseTracking
,height
,heightForWidth
,hide
,hideEvent
,inputContext
,inputMethodEvent
,inputMethodHints
,inputMethodQuery
,insertAction
,insertActions
,isActiveWindow
,isAncestorOf
,isEnabled
,isEnabledTo
,isFullScreen
,isHidden
,isLeftToRight
,isMaximized
,isMinimized
,isModal
,isRightToLeft
,isVisible
,isVisibleTo
,isWindow
,isWindowModified
,keyboardGrabber
,keyPressEvent
,keyReleaseEvent
,languageChange
,layout
,layoutDirection
,leaveEvent
,locale
,lower
,mapFrom
,mapFromGlobal
,mapFromParent
,mapTo
,mapToGlobal
,mapToParent
,mask
,maximumHeight
,maximumSize
,maximumWidth
,metric
,minimumHeight
,minimumSize
,minimumSizeHint
,minimumWidth
,mouseDoubleClickEvent
,mouseGrabber
,mouseMoveEvent
,mousePressEvent
,mouseReleaseEvent
,move
,moveEvent
,nativeParentWidget
,nextInFocusChain
,normalGeometry
,overrideWindowFlags
,overrideWindowState
,paintEngine
,paintEvent
,palette
,parentWidget
,pos
,previousInFocusChain
,raise_
,rect
,releaseKeyboard
,releaseMouse
,releaseShortcut
,removeAction
,render
,repaint
,resetInputContext
,resize
,resizeEvent
,restoreGeometry
,saveGeometry
,scroll
,setAcceptDrops
,setAccessibleDescription
,setAccessibleName
,setAttribute
,setAutoFillBackground
,setBackgroundRole
,setBaseSize
,setContentsMargins
,setContextMenuPolicy
,setCursor
,setDisabled
,setEnabled
,setFixedHeight
,setFixedSize
,setFixedWidth
,setFocus
,setFocusPolicy
,setFocusProxy
,setFont
,setForegroundRole
,setGeometry
,setGraphicsEffect
,setHidden
,setInputContext
,setInputMethodHints
,setLayout
,setLayoutDirection
,setLocale
,setMask
,setMaximumHeight
,setMaximumSize
,setMaximumWidth
,setMinimumHeight
,setMinimumSize
,setMinimumWidth
,setMouseTracking
,setPalette
,setParent
,setShortcutAutoRepeat
,setShortcutEnabled
,setSizeIncrement
,setSizePolicy
,setStatusTip
,setStyle
,setStyleSheet
,setTabOrder
,setToolTip
,setUpdatesEnabled
,setVisible
,setWhatsThis
,setWindowFilePath
,setWindowFlags
,setWindowIcon
,setWindowIconText
,setWindowModality
,setWindowModified
,setWindowOpacity
,setWindowRole
,setWindowState
,setWindowTitle
,show
,showEvent
,showFullScreen
,showMaximized
,showMinimized
,showNormal
,size
,sizeHint
,sizeIncrement
,sizePolicy
,stackUnder
,statusTip
,style
,styleSheet
,tabletEvent
,testAttribute
,toolTip
,underMouse
,ungrabGesture
,unsetCursor
,unsetLayoutDirection
,unsetLocale
,update
,updateGeometry
,updateMicroFocus
,updatesEnabled
,visibleRegion
,whatsThis
,wheelEvent
,width
,window
,windowFilePath
,windowFlags
,windowIcon
,windowIconText
,windowModality
,windowOpacity
,windowRole
,windowState
,windowTitle
,windowType
,winId
,x
,x11Info
,x11PictureHandle
,y
,__new__
QObject
blockSignals
,childEvent
,children
,connect
,connectNotify
,customEvent
,deleteLater
,disconnect
,disconnectNotify
,dumpObjectInfo
,dumpObjectTree
,dynamicPropertyNames
,emit
,eventFilter
,findChild
,findChildren
,inherits
,installEventFilter
,isWidgetType
,killTimer
,metaObject
,moveToThread
,objectName
,parent
,property
,receivers
,registerUserData
,removeEventFilter
,sender
,senderSignalIndex
,setObjectName
,setProperty
,signalsBlocked
,startTimer
,thread
,timerEvent
,tr
,trUtf8
QPaintDevice
colorCount
,depth
,heightMM
,logicalDpiX
,logicalDpiY
,numColors
,paintingActive
,physicalDpiX
,physicalDpiY
,widthMM
Attributes
ParamRuler
staticMetaObject
QWidget
customContextMenuRequested
,DrawChildren
,DrawWindowBackground
,IgnoreMask
,RenderFlag
,RenderFlags
QObject
destroyed
QPaintDevice
PaintDeviceMetric
,painters
,PdmDepth
,PdmDpiX
,PdmDpiY
,PdmHeight
,PdmHeightMM
,PdmNumColors
,PdmPhysicalDpiX
,PdmPhysicalDpiY
,PdmWidth
,PdmWidthMM
-
class
pymordemos.thermalblock_gui.
RBGui
(args)[source]¶ Bases:
PySide.QtGui.QMainWindow
Methods
QMainWindow
addDockWidget
,addToolBar
,addToolBarBreak
,centralWidget
,contextMenuEvent
,corner
,createPopupMenu
,dockOptions
,dockWidgetArea
,documentMode
,event
,iconSize
,insertToolBar
,insertToolBarBreak
,isAnimated
,isDockNestingEnabled
,isSeparator
,menuBar
,menuWidget
,removeDockWidget
,removeToolBar
,removeToolBarBreak
,restoreDockWidget
,restoreState
,saveState
,setAnimated
,setCentralWidget
,setCorner
,setDockNestingEnabled
,setDockOptions
,setDocumentMode
,setIconSize
,setMenuBar
,setMenuWidget
,setStatusBar
,setTabPosition
,setTabShape
,setToolButtonStyle
,setUnifiedTitleAndToolBarOnMac
,splitDockWidget
,statusBar
,tabifiedDockWidgets
,tabifyDockWidget
,tabPosition
,tabShape
,toolBarArea
,toolBarBreak
,toolButtonStyle
,unifiedTitleAndToolBarOnMac
,__new__
QWidget
acceptDrops
,accessibleDescription
,accessibleName
,actionEvent
,actions
,activateWindow
,addAction
,addActions
,adjustSize
,autoFillBackground
,backgroundRole
,baseSize
,changeEvent
,childAt
,childrenRect
,childrenRegion
,clearFocus
,clearMask
,close
,closeEvent
,contentsMargins
,contentsRect
,contextMenuPolicy
,createWinId
,cursor
,destroy
,devType
,dragEnterEvent
,dragLeaveEvent
,dragMoveEvent
,dropEvent
,effectiveWinId
,ensurePolished
,enterEvent
,focusInEvent
,focusNextChild
,focusNextPrevChild
,focusOutEvent
,focusPolicy
,focusPreviousChild
,focusProxy
,focusWidget
,font
,fontInfo
,fontMetrics
,foregroundRole
,frameGeometry
,frameSize
,geometry
,getContentsMargins
,grabGesture
,grabKeyboard
,grabMouse
,grabShortcut
,graphicsEffect
,graphicsProxyWidget
,hasFocus
,hasMouseTracking
,height
,heightForWidth
,hide
,hideEvent
,inputContext
,inputMethodEvent
,inputMethodHints
,inputMethodQuery
,insertAction
,insertActions
,isActiveWindow
,isAncestorOf
,isEnabled
,isEnabledTo
,isFullScreen
,isHidden
,isLeftToRight
,isMaximized
,isMinimized
,isModal
,isRightToLeft
,isVisible
,isVisibleTo
,isWindow
,isWindowModified
,keyboardGrabber
,keyPressEvent
,keyReleaseEvent
,languageChange
,layout
,layoutDirection
,leaveEvent
,locale
,lower
,mapFrom
,mapFromGlobal
,mapFromParent
,mapTo
,mapToGlobal
,mapToParent
,mask
,maximumHeight
,maximumSize
,maximumWidth
,metric
,minimumHeight
,minimumSize
,minimumSizeHint
,minimumWidth
,mouseDoubleClickEvent
,mouseGrabber
,mouseMoveEvent
,mousePressEvent
,mouseReleaseEvent
,move
,moveEvent
,nativeParentWidget
,nextInFocusChain
,normalGeometry
,overrideWindowFlags
,overrideWindowState
,paintEngine
,paintEvent
,palette
,parentWidget
,pos
,previousInFocusChain
,raise_
,rect
,releaseKeyboard
,releaseMouse
,releaseShortcut
,removeAction
,render
,repaint
,resetInputContext
,resize
,resizeEvent
,restoreGeometry
,saveGeometry
,scroll
,setAcceptDrops
,setAccessibleDescription
,setAccessibleName
,setAttribute
,setAutoFillBackground
,setBackgroundRole
,setBaseSize
,setContentsMargins
,setContextMenuPolicy
,setCursor
,setDisabled
,setEnabled
,setFixedHeight
,setFixedSize
,setFixedWidth
,setFocus
,setFocusPolicy
,setFocusProxy
,setFont
,setForegroundRole
,setGeometry
,setGraphicsEffect
,setHidden
,setInputContext
,setInputMethodHints
,setLayout
,setLayoutDirection
,setLocale
,setMask
,setMaximumHeight
,setMaximumSize
,setMaximumWidth
,setMinimumHeight
,setMinimumSize
,setMinimumWidth
,setMouseTracking
,setPalette
,setParent
,setShortcutAutoRepeat
,setShortcutEnabled
,setSizeIncrement
,setSizePolicy
,setStatusTip
,setStyle
,setStyleSheet
,setTabOrder
,setToolTip
,setUpdatesEnabled
,setVisible
,setWhatsThis
,setWindowFilePath
,setWindowFlags
,setWindowIcon
,setWindowIconText
,setWindowModality
,setWindowModified
,setWindowOpacity
,setWindowRole
,setWindowState
,setWindowTitle
,show
,showEvent
,showFullScreen
,showMaximized
,showMinimized
,showNormal
,size
,sizeHint
,sizeIncrement
,sizePolicy
,stackUnder
,statusTip
,style
,styleSheet
,tabletEvent
,testAttribute
,toolTip
,underMouse
,ungrabGesture
,unsetCursor
,unsetLayoutDirection
,unsetLocale
,update
,updateGeometry
,updateMicroFocus
,updatesEnabled
,visibleRegion
,whatsThis
,wheelEvent
,width
,window
,windowFilePath
,windowFlags
,windowIcon
,windowIconText
,windowModality
,windowOpacity
,windowRole
,windowState
,windowTitle
,windowType
,winId
,x
,x11Info
,x11PictureHandle
,y
QObject
blockSignals
,childEvent
,children
,connect
,connectNotify
,customEvent
,deleteLater
,disconnect
,disconnectNotify
,dumpObjectInfo
,dumpObjectTree
,dynamicPropertyNames
,emit
,eventFilter
,findChild
,findChildren
,inherits
,installEventFilter
,isWidgetType
,killTimer
,metaObject
,moveToThread
,objectName
,parent
,property
,receivers
,registerUserData
,removeEventFilter
,sender
,senderSignalIndex
,setObjectName
,setProperty
,signalsBlocked
,startTimer
,thread
,timerEvent
,tr
,trUtf8
QPaintDevice
colorCount
,depth
,heightMM
,logicalDpiX
,logicalDpiY
,numColors
,paintingActive
,physicalDpiX
,physicalDpiY
,widthMM
Attributes
RBGui
staticMetaObject
QMainWindow
AllowNestedDocks
,AllowTabbedDocks
,AnimatedDocks
,DockOption
,DockOptions
,ForceTabbedDocks
,iconSizeChanged
,toolButtonStyleChanged
,VerticalTabs
QWidget
customContextMenuRequested
,DrawChildren
,DrawWindowBackground
,IgnoreMask
,RenderFlag
,RenderFlags
QObject
destroyed
QPaintDevice
PaintDeviceMetric
,painters
,PdmDepth
,PdmDpiX
,PdmDpiY
,PdmHeight
,PdmHeightMM
,PdmNumColors
,PdmPhysicalDpiX
,PdmPhysicalDpiY
,PdmWidth
,PdmWidthMM
-
class
pymordemos.thermalblock_gui.
ReducedSim
(args)[source]¶ Bases:
pymordemos.thermalblock_gui.SimBase
Methods
ReducedSim
solve
-
class
pymordemos.thermalblock_gui.
SimPanel
(parent, sim)[source]¶ Bases:
PySide.QtGui.QWidget
Methods
SimPanel
solve_update
QWidget
acceptDrops
,accessibleDescription
,accessibleName
,actionEvent
,actions
,activateWindow
,addAction
,addActions
,adjustSize
,autoFillBackground
,backgroundRole
,baseSize
,changeEvent
,childAt
,childrenRect
,childrenRegion
,clearFocus
,clearMask
,close
,closeEvent
,contentsMargins
,contentsRect
,contextMenuEvent
,contextMenuPolicy
,createWinId
,cursor
,destroy
,devType
,dragEnterEvent
,dragLeaveEvent
,dragMoveEvent
,dropEvent
,effectiveWinId
,ensurePolished
,enterEvent
,event
,focusInEvent
,focusNextChild
,focusNextPrevChild
,focusOutEvent
,focusPolicy
,focusPreviousChild
,focusProxy
,focusWidget
,font
,fontInfo
,fontMetrics
,foregroundRole
,frameGeometry
,frameSize
,geometry
,getContentsMargins
,grabGesture
,grabKeyboard
,grabMouse
,grabShortcut
,graphicsEffect
,graphicsProxyWidget
,hasFocus
,hasMouseTracking
,height
,heightForWidth
,hide
,hideEvent
,inputContext
,inputMethodEvent
,inputMethodHints
,inputMethodQuery
,insertAction
,insertActions
,isActiveWindow
,isAncestorOf
,isEnabled
,isEnabledTo
,isFullScreen
,isHidden
,isLeftToRight
,isMaximized
,isMinimized
,isModal
,isRightToLeft
,isVisible
,isVisibleTo
,isWindow
,isWindowModified
,keyboardGrabber
,keyPressEvent
,keyReleaseEvent
,languageChange
,layout
,layoutDirection
,leaveEvent
,locale
,lower
,mapFrom
,mapFromGlobal
,mapFromParent
,mapTo
,mapToGlobal
,mapToParent
,mask
,maximumHeight
,maximumSize
,maximumWidth
,metric
,minimumHeight
,minimumSize
,minimumSizeHint
,minimumWidth
,mouseDoubleClickEvent
,mouseGrabber
,mouseMoveEvent
,mousePressEvent
,mouseReleaseEvent
,move
,moveEvent
,nativeParentWidget
,nextInFocusChain
,normalGeometry
,overrideWindowFlags
,overrideWindowState
,paintEngine
,paintEvent
,palette
,parentWidget
,pos
,previousInFocusChain
,raise_
,rect
,releaseKeyboard
,releaseMouse
,releaseShortcut
,removeAction
,render
,repaint
,resetInputContext
,resize
,resizeEvent
,restoreGeometry
,saveGeometry
,scroll
,setAcceptDrops
,setAccessibleDescription
,setAccessibleName
,setAttribute
,setAutoFillBackground
,setBackgroundRole
,setBaseSize
,setContentsMargins
,setContextMenuPolicy
,setCursor
,setDisabled
,setEnabled
,setFixedHeight
,setFixedSize
,setFixedWidth
,setFocus
,setFocusPolicy
,setFocusProxy
,setFont
,setForegroundRole
,setGeometry
,setGraphicsEffect
,setHidden
,setInputContext
,setInputMethodHints
,setLayout
,setLayoutDirection
,setLocale
,setMask
,setMaximumHeight
,setMaximumSize
,setMaximumWidth
,setMinimumHeight
,setMinimumSize
,setMinimumWidth
,setMouseTracking
,setPalette
,setParent
,setShortcutAutoRepeat
,setShortcutEnabled
,setSizeIncrement
,setSizePolicy
,setStatusTip
,setStyle
,setStyleSheet
,setTabOrder
,setToolTip
,setUpdatesEnabled
,setVisible
,setWhatsThis
,setWindowFilePath
,setWindowFlags
,setWindowIcon
,setWindowIconText
,setWindowModality
,setWindowModified
,setWindowOpacity
,setWindowRole
,setWindowState
,setWindowTitle
,show
,showEvent
,showFullScreen
,showMaximized
,showMinimized
,showNormal
,size
,sizeHint
,sizeIncrement
,sizePolicy
,stackUnder
,statusTip
,style
,styleSheet
,tabletEvent
,testAttribute
,toolTip
,underMouse
,ungrabGesture
,unsetCursor
,unsetLayoutDirection
,unsetLocale
,update
,updateGeometry
,updateMicroFocus
,updatesEnabled
,visibleRegion
,whatsThis
,wheelEvent
,width
,window
,windowFilePath
,windowFlags
,windowIcon
,windowIconText
,windowModality
,windowOpacity
,windowRole
,windowState
,windowTitle
,windowType
,winId
,x
,x11Info
,x11PictureHandle
,y
,__new__
QObject
blockSignals
,childEvent
,children
,connect
,connectNotify
,customEvent
,deleteLater
,disconnect
,disconnectNotify
,dumpObjectInfo
,dumpObjectTree
,dynamicPropertyNames
,emit
,eventFilter
,findChild
,findChildren
,inherits
,installEventFilter
,isWidgetType
,killTimer
,metaObject
,moveToThread
,objectName
,parent
,property
,receivers
,registerUserData
,removeEventFilter
,sender
,senderSignalIndex
,setObjectName
,setProperty
,signalsBlocked
,startTimer
,thread
,timerEvent
,tr
,trUtf8
QPaintDevice
colorCount
,depth
,heightMM
,logicalDpiX
,logicalDpiY
,numColors
,paintingActive
,physicalDpiX
,physicalDpiY
,widthMM
Attributes
SimPanel
staticMetaObject
QWidget
customContextMenuRequested
,DrawChildren
,DrawWindowBackground
,IgnoreMask
,RenderFlag
,RenderFlags
QObject
destroyed
QPaintDevice
PaintDeviceMetric
,painters
,PdmDepth
,PdmDpiX
,PdmDpiY
,PdmHeight
,PdmHeightMM
,PdmNumColors
,PdmPhysicalDpiX
,PdmPhysicalDpiY
,PdmWidth
,PdmWidthMM
thermalblock_simple module¶
Simplified version of the thermalblock demo.
- Usage:
- thermalblock_simple.py [options] MODEL ALG SNAPSHOTS RBSIZE TEST
- Arguments:
MODEL High-dimensional model (pymor, fenics).
- ALG The model reduction algorithm to use
- (naive, greedy, adaptive_greedy, pod).
SNAPSHOTS naive: ignored
- greedy/pod: Number of training_set parameters per block
- (in total SNAPSHOTS^(XBLOCKS * YBLOCKS) parameters).
adaptive_greedy: size of validation set.
RBSIZE Size of the reduced basis.
TEST Number of parameters for stochastic error estimation.
-
pymordemos.thermalblock_simple.
reduce_adaptive_greedy
(d, reductor, validation_mus, basis_size)[source]¶