mirror of
https://github.com/OPM/ResInsight.git
synced 2025-02-25 18:55:39 -06:00
RFT ensemble refactoring
* Compute average MD for intersections with a cell * Create extractor for simulation well * Remove rftReader from RifDataSourceForRftPlt * Add function compute measured depth for RFT cells based on well path geometry * Move statistics reader to well ensemble curve set * Make sure both TVD and MD are cached if possible * Add selection of grid case to use for estimation of measured depth (MD) Add "Grid Model For MD" where the user can select a grid model. This grid model is propagated to a hidden field in EnsembleCurveSet. The grid model is then applied to RifReaderEnsembleStatisticsRft owned by EnsembleCurveSet
This commit is contained in:
@@ -18,10 +18,14 @@
|
||||
|
||||
#include "RimWellRftEnsembleCurveSet.h"
|
||||
|
||||
#include "RifReaderEnsembleStatisticsRft.h"
|
||||
|
||||
#include "RimEclipseCase.h"
|
||||
#include "RimEnsembleCurveSetColorManager.h"
|
||||
#include "RimRegularLegendConfig.h"
|
||||
#include "RimSummaryCase.h"
|
||||
#include "RimSummaryCaseCollection.h"
|
||||
#include "RimTools.h"
|
||||
#include "RimWellRftPlot.h"
|
||||
|
||||
#include "RiuQwtPlotWidget.h"
|
||||
@@ -59,6 +63,9 @@ RimWellRftEnsembleCurveSet::RimWellRftEnsembleCurveSet()
|
||||
m_ensembleLegendConfig = new RimRegularLegendConfig();
|
||||
m_ensembleLegendConfig->setColorLegend(
|
||||
RimRegularLegendConfig::mapToColorLegend( RimEnsembleCurveSetColorManager::DEFAULT_ENSEMBLE_COLOR_RANGE ) );
|
||||
|
||||
CAF_PDM_InitFieldNoDefault( &m_eclipseCase, "EclipseResultCase", "Eclipse Result Case" );
|
||||
m_eclipseCase.uiCapability()->setUiHidden( true );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -76,9 +83,14 @@ RimSummaryCaseCollection* RimWellRftEnsembleCurveSet::ensemble() const
|
||||
return m_ensemble;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimWellRftEnsembleCurveSet::setEnsemble( RimSummaryCaseCollection* ensemble )
|
||||
{
|
||||
m_ensemble = ensemble;
|
||||
|
||||
clearEnsembleStatistics();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -150,6 +162,22 @@ std::vector<QString> RimWellRftEnsembleCurveSet::parametersWithVariation() const
|
||||
return std::vector<QString>( paramSet.begin(), paramSet.end() );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimWellRftEnsembleCurveSet::clearEnsembleStatistics()
|
||||
{
|
||||
m_statisticsEclipseRftReader = new RifReaderEnsembleStatisticsRft( m_ensemble(), m_eclipseCase() );
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimWellRftEnsembleCurveSet::initAfterRead()
|
||||
{
|
||||
clearEnsembleStatistics();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -177,6 +205,31 @@ RigEnsembleParameter::Type RimWellRftEnsembleCurveSet::currentEnsembleParameterT
|
||||
return RigEnsembleParameter::TYPE_NONE;
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
void RimWellRftEnsembleCurveSet::setEclipseCase( RimEclipseCase* eclipseCase )
|
||||
{
|
||||
m_eclipseCase = eclipseCase;
|
||||
clearEnsembleStatistics();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RimEclipseCase* RimWellRftEnsembleCurveSet::eclipseCase() const
|
||||
{
|
||||
return m_eclipseCase();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
RifReaderRftInterface* RimWellRftEnsembleCurveSet::statisticsEclipseRftReader()
|
||||
{
|
||||
return m_statisticsEclipseRftReader.p();
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
///
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -188,6 +241,10 @@ void RimWellRftEnsembleCurveSet::fieldChangedByUi( const caf::PdmFieldHandle* ch
|
||||
rftPlot->syncCurvesFromUiSelection();
|
||||
rftPlot->updateConnectedEditors();
|
||||
}
|
||||
else if ( changedField == &m_eclipseCase )
|
||||
{
|
||||
clearEnsembleStatistics();
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------
|
||||
@@ -203,6 +260,12 @@ QList<caf::PdmOptionItemInfo> RimWellRftEnsembleCurveSet::calculateValueOptions(
|
||||
options.push_back( caf::PdmOptionItemInfo( param, param ) );
|
||||
}
|
||||
}
|
||||
else if ( fieldNeedingOptions == &m_eclipseCase )
|
||||
{
|
||||
RimTools::caseOptionItems( &options );
|
||||
|
||||
options.push_front( caf::PdmOptionItemInfo( "None", nullptr ) );
|
||||
}
|
||||
return options;
|
||||
}
|
||||
|
||||
@@ -218,6 +281,9 @@ void RimWellRftEnsembleCurveSet::defineUiOrdering( QString uiConfigName, caf::Pd
|
||||
{
|
||||
colorsGroup->add( &m_ensembleParameter );
|
||||
}
|
||||
|
||||
uiOrdering.add( &m_eclipseCase );
|
||||
|
||||
uiOrdering.skipRemainingFields( true );
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user