mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
Fault Reactivation Assessment: updates and tweaks (#7732)
* Add flag to keep temp. parameter files or not. * Ask user if it is ok to clean the output folder if selected. * Add property for elastic table input file. * Do not show legend by default when refreshing tsurfs * Make sure all loadsteps are enabled in post processing json file * Support running adv. proc without req. basic proc to be run first
This commit is contained in:
@@ -28,6 +28,7 @@
|
||||
#include "cafPdmFieldScriptingCapability.h"
|
||||
#include "cafPdmObjectScriptingCapability.h"
|
||||
#include "cafPdmUiComboBoxEditor.h"
|
||||
#include "cafPdmUiFilePathEditor.h"
|
||||
|
||||
#include <QDir>
|
||||
#include <QFileInfo>
|
||||
@@ -62,6 +63,10 @@ RimFaultRAPreprocSettings::RimFaultRAPreprocSettings()
|
||||
|
||||
CAF_PDM_InitField( &m_cleanBaseDir, "CleanBaseDir", false, "Clean Output Directory", "", "", "" );
|
||||
CAF_PDM_InitField( &m_smoothEclipseData, "SmoothEclipseData", true, "Smooth Eclipse Data", "", "", "" );
|
||||
|
||||
CAF_PDM_InitField( &m_elasticTableFilename, "ElasticTableFilename", QString( "" ), "Elastic Table", "", "", "" );
|
||||
m_elasticTableFilename.uiCapability()->setUiEditorTypeName( caf::PdmUiFilePathEditor::uiEditorTypeName() );
|
||||
m_elasticTableFilename.uiCapability()->setUiLabelPosition( caf::PdmUiItemInfo::HIDDEN );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -104,6 +109,9 @@ void RimFaultRAPreprocSettings::defineUiOrdering( QString uiConfigName, caf::Pdm
|
||||
geomechGroup->add( &m_geomechCase );
|
||||
geomechGroup->add( &m_startTimestepGeoMech );
|
||||
geomechGroup->add( &m_endTimestepGeoMech );
|
||||
|
||||
auto tableGroup = uiOrdering.addNewGroup( "Elastic Table" );
|
||||
tableGroup->add( &m_elasticTableFilename );
|
||||
}
|
||||
|
||||
auto eclipseGroup = uiOrdering.addNewGroup( "Eclipse Model" );
|
||||
@@ -271,6 +279,14 @@ QString RimFaultRAPreprocSettings::geomechCaseFilename() const
|
||||
return "";
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
QString RimFaultRAPreprocSettings::elasticTableFilename() const
|
||||
{
|
||||
return m_elasticTableFilename();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -295,6 +311,14 @@ bool RimFaultRAPreprocSettings::cleanBaseDirectory() const
|
||||
return m_cleanBaseDir();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimFaultRAPreprocSettings::setCleanBaseDirectory( bool clean )
|
||||
{
|
||||
m_cleanBaseDir = clean;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -55,8 +55,11 @@ public:
|
||||
|
||||
QString eclipseCaseFilename() const;
|
||||
QString geomechCaseFilename() const;
|
||||
bool cleanBaseDirectory() const;
|
||||
bool smoothEclipseData() const;
|
||||
QString elasticTableFilename() const;
|
||||
|
||||
bool cleanBaseDirectory() const;
|
||||
void setCleanBaseDirectory( bool clean );
|
||||
|
||||
bool geoMechSelected() const;
|
||||
|
||||
@@ -90,4 +93,5 @@ protected:
|
||||
caf::PdmPtrField<RimGeoMechCase*> m_geomechCase;
|
||||
caf::PdmField<QString> m_baseDir;
|
||||
caf::PdmField<bool> m_cleanBaseDir;
|
||||
caf::PdmField<QString> m_elasticTableFilename;
|
||||
};
|
||||
|
||||
@@ -38,6 +38,7 @@
|
||||
#include "cafPdmFieldScriptingCapability.h"
|
||||
#include "cafPdmObjectScriptingCapability.h"
|
||||
#include "cafPdmUiComboBoxEditor.h"
|
||||
#include "cafPdmUiFilePathEditor.h"
|
||||
#include "cafPdmUiTableViewEditor.h"
|
||||
|
||||
#include <QFileInfo>
|
||||
@@ -63,6 +64,10 @@ RimFaultRASettings::RimFaultRASettings()
|
||||
CAF_PDM_InitFieldNoDefault( &m_baseDir, "BaseDir", "Working Directory", "", "", "" );
|
||||
m_baseDir.uiCapability()->setUiReadOnly( true );
|
||||
|
||||
CAF_PDM_InitField( &m_elasticTableFilename, "ElasticTableFilename", QString( "" ), "Elastic Table", "", "", "" );
|
||||
m_elasticTableFilename.uiCapability()->setUiEditorTypeName( caf::PdmUiFilePathEditor::uiEditorTypeName() );
|
||||
m_elasticTableFilename.uiCapability()->setUiLabelPosition( caf::PdmUiItemInfo::TOP );
|
||||
|
||||
CAF_PDM_InitField( &m_startTimestepEclipse, "StartTimeStepEclipse", 0, "Start Time Step", "", "", "" );
|
||||
m_startTimestepEclipse.uiCapability()->setUiEditorTypeName( caf::PdmUiComboBoxEditor::uiEditorTypeName() );
|
||||
CAF_PDM_InitField( &m_endTimestepEclipse, "EndTimeStepEclipse", 0, "End Time Step", "", "", "" );
|
||||
@@ -85,6 +90,7 @@ RimFaultRASettings::RimFaultRASettings()
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_basicParametersRI, "BasicParametersRI", "Basic ResInsight Parameters", "", "", "" );
|
||||
CAF_PDM_InitFieldNoDefault( &m_advancedParametersRI, "AdvancedParametersRI", "Advanced ResInsight Parameters", "", "", "" );
|
||||
|
||||
setupResInsightParameters();
|
||||
}
|
||||
|
||||
@@ -154,6 +160,9 @@ void RimFaultRASettings::defineUiOrdering( QString uiConfigName, caf::PdmUiOrder
|
||||
auto geomechGroup = uiOrdering.addNewGroup( "GeoMech Time Steps" );
|
||||
geomechGroup->add( &m_startTimestepGeoMech );
|
||||
geomechGroup->add( &m_endTimestepGeoMech );
|
||||
|
||||
auto tableGroup = uiOrdering.addNewGroup( "Additional Settings" );
|
||||
tableGroup->add( &m_elasticTableFilename );
|
||||
}
|
||||
uiOrdering.skipRemainingFields( true );
|
||||
}
|
||||
@@ -247,6 +256,7 @@ void RimFaultRASettings::initFromPreprocSettings( RimFaultRAPreprocSettings* pre
|
||||
m_endTimestepEclipse = preprocSettings->endTimeStepEclipseIndex();
|
||||
m_startTimestepGeoMech = preprocSettings->startTimeStepGeoMechIndex();
|
||||
m_endTimestepGeoMech = preprocSettings->endTimeStepGeoMechIndex();
|
||||
m_elasticTableFilename = preprocSettings->elasticTableFilename();
|
||||
|
||||
QString errorText;
|
||||
|
||||
@@ -455,7 +465,7 @@ void RimFaultRASettings::setupResInsightParameters()
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
QString RimFaultRASettings::elasticPropertiesFilename() const
|
||||
{
|
||||
return m_baseDir + "/Abaqus/ELASTIC_TABLE_res.inp";
|
||||
return m_elasticTableFilename;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
|
||||
@@ -101,6 +101,7 @@ private:
|
||||
caf::PdmPtrField<RimEclipseCase*> m_eclipseCase;
|
||||
caf::PdmPtrField<RimGeoMechCase*> m_geomechCase;
|
||||
caf::PdmField<QString> m_baseDir;
|
||||
caf::PdmField<QString> m_elasticTableFilename;
|
||||
|
||||
caf::PdmField<int> m_startTimestepEclipse;
|
||||
caf::PdmField<int> m_endTimestepEclipse;
|
||||
|
||||
Reference in New Issue
Block a user