Summary connections and completions (#12156)

* Add category WELL_CONNECTION
* Throw exception if category string is invalid
* Make it possible to step connections
* Add definition of completion vectors
* Use WELL_CONNECTION for CPRL
* Convert "WGPRL__2:MY-WELL1-A5" to "WGPRL:MY-WELL1-A5:2"
Use the syntax for well completions in opm-common
* More tests for different variants of summary texts
This commit is contained in:
Magne Sjaastad 2025-02-13 08:31:53 +01:00 committed by GitHub
parent ad310714c2
commit 865fbf0cba
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
42 changed files with 1410 additions and 729 deletions

View File

@ -321,5 +321,6 @@
<file>components/images/unknown.svg</file>
<file>components/images/well.svg</file>
<file>components/images/well-completion.svg</file>
<file>components/images/well-completion-01.svg</file>
</qresource>
</RCC>

View File

@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px"
viewBox="0 0 24 24" xml:space="preserve">
<g>
<path style="fill:#5F6368;" d="M20.7,7.5C20.6,7.2,20.3,7,20,6.8l-4-2.3v2.3l1.9,1.1L12,11.4L6.1,7.9L8,6.8V4.5L4,6.8C3.7,7,3.4,7.2,3.3,7.5
C3.1,7.8,3,8.2,3,8.5v8c0,0.4,0.1,0.7,0.3,1S3.7,18,4,18.2l7,4c0.3,0.2,0.7,0.3,1,0.3s0.7-0.1,1-0.3l7-4c0.3-0.2,0.6-0.4,0.7-0.7
s0.3-0.6,0.3-1v-8C21,8.2,20.9,7.8,20.7,7.5z M11,19.9l-6-3.5V9.6l6,3.5V19.9z M19,16.5l-6,3.5v-6.8l6-3.5V16.5z"/>
<path style="fill:#5F6368;" d="M12,8.5c0.6,0,1-0.2,1-0.5V7.5v-4V3c0-0.3-0.4-0.5-1-0.5S11,2.7,11,3v0.5v4V8C11,8.3,11.4,8.5,12,8.5z"/>
</g>
</svg>

After

Width:  |  Height:  |  Size: 738 B

View File

@ -11,7 +11,7 @@
<line class="st0" x1="12" y1="5.8" x2="12" y2="22.6"/>
<line class="st1" x1="6.8" y1="18.5" x2="17.6" y2="20.2"/>
<line class="st1" x1="9.4" y1="10.7" x2="15" y2="12.3"/>
<path stroke="#5F6368" fill="#5F6368"d="M3.7,13.6"/>
<path stroke="#5F6368" fill="#5F6368" d="M3.7,13.6"/>
<path stroke="#5F6368" fill="#5F6368" d="M12.5,10.2h-1c-0.9,0-2.8-1.7-2.9-1.7V7.3c0-0.3,0.2-0.5,0.5-0.5H15c0.3,0,0.5,0.2,0.5,0.5v1.2
C15.5,8.5,13.4,10.2,12.5,10.2z"/>
<path stroke="#5F6368" fill="#5F6368" d="M16.5,16.1H7.4c-0.4,0-0.7-0.3-0.7-0.7v-0.2c0-0.4,0.3-0.7,0.7-0.7h9.1c0.4,0,0.7,0.3,0.7,0.7v0.2

Before

Width:  |  Height:  |  Size: 1.9 KiB

After

Width:  |  Height:  |  Size: 1.9 KiB

View File

@ -1032,11 +1032,11 @@
"description": "Total Mole Fraction (Component 2) (Matrix 4)"
},
"CFGAS": {
"category": "SUMMARY_WELL_COMPLETION",
"category": "SUMMARY_WELL_CONNECTION",
"description": "Gas Flow Rate"
},
"CPDIAM": {
"category": "SUMMARY_WELL_COMPLETION",
"category": "SUMMARY_WELL_CONNECTION",
"description": "Perforation Diameter"
},
"FDG": {
@ -1116,15 +1116,15 @@
"description": "Liquid Injection Total"
},
"INFLOW0": {
"category": "SUMMARY_WELL_COMPLETION",
"category": "SUMMARY_WELL_CONNECTION",
"description": "Inflow Rate (Component 0)"
},
"INFLOW1": {
"category": "SUMMARY_WELL_COMPLETION",
"category": "SUMMARY_WELL_CONNECTION",
"description": "Inflow Rate (Component 1)"
},
"INFLOW2": {
"category": "SUMMARY_WELL_COMPLETION",
"category": "SUMMARY_WELL_CONNECTION",
"description": "Inflow Rate (Component 2)"
},
"MEMORYTS": {
@ -1136,7 +1136,7 @@
"description": "Number of Tracer Linear Iterations at the Current Time-Step"
},
"MSDEPTH": {
"category": "SUMMARY_WELL_COMPLETION",
"category": "SUMMARY_WELL_CONNECTION",
"description": "Depth of Well Completion"
},
"MSUMCHOP": {

View File

@ -93,13 +93,16 @@ caf::PdmOptionItemInfo RiaOptionItemFactory::optionItemFromSummaryType( RifEclip
iconText = ":/summary/components/images/well.svg";
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION:
iconText = ":/summary/components/images/well-completion.svg";
iconText = ":/summary/components/images/well.svg";
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION:
iconText = ":/summary/components/images/block.svg";
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_LGR:
iconText = ":/summary/components/images/well.svg";
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION_LGR:
iconText = ":/summary/components/images/well-completion.svg";
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION_LGR:
iconText = ":/summary/components/images/block.svg";
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_SEGMENT:
iconText = ":/summary/components/images/segment.svg";

View File

@ -202,11 +202,11 @@ std::set<int> RiaSummaryAddressAnalyzer::regionNumbers() const
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
std::set<std::string> RiaSummaryAddressAnalyzer::wellCompletions( const std::string& wellName ) const
std::set<std::string> RiaSummaryAddressAnalyzer::wellConnections( const std::string& wellName ) const
{
std::set<std::string> connections;
for ( const auto& conn : m_wellCompletions )
for ( const auto& conn : m_wellConnections )
{
if ( conn.first == wellName )
{
@ -251,6 +251,24 @@ std::set<int> RiaSummaryAddressAnalyzer::aquifers() const
return keysInMap( m_aquifers );
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
std::set<int> RiaSummaryAddressAnalyzer::wellCompletionNumbers( const std::string& wellName ) const
{
std::set<int> numbers;
for ( const auto& wellAndNumber : m_wellCompletionNumbers )
{
if ( wellName.empty() || std::get<0>( wellAndNumber ) == wellName )
{
numbers.insert( std::get<1>( wellAndNumber ) );
}
}
return numbers;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
@ -342,7 +360,15 @@ std::vector<QString> RiaSummaryAddressAnalyzer::identifierTexts( RifEclipseSumma
}
else if ( category == SummaryCategory::SUMMARY_WELL_COMPLETION )
{
auto connections = wellCompletions( secondaryIdentifier );
auto numbers = wellCompletionNumbers( secondaryIdentifier );
for ( const auto& number : numbers )
{
identifierStrings.push_back( QString::number( number ) );
}
}
else if ( category == SummaryCategory::SUMMARY_WELL_CONNECTION )
{
auto connections = wellConnections( secondaryIdentifier );
for ( const auto& conn : connections )
{
identifierStrings.push_back( QString::fromStdString( conn ) );
@ -417,8 +443,9 @@ void RiaSummaryAddressAnalyzer::clear()
m_networkNames.clear();
m_regionNumbers.clear();
m_categories.clear();
m_wellCompletions.clear();
m_wellConnections.clear();
m_wellSegmentNumbers.clear();
m_wellCompletionNumbers.clear();
m_blocks.clear();
m_aquifers.clear();
@ -512,15 +539,18 @@ void RiaSummaryAddressAnalyzer::analyzeSingleAddress( const RifEclipseSummaryAdd
m_networkNames.insert( { address.networkName(), address } );
}
if ( address.regionNumber() != -1 )
if ( address.category() == SummaryCategory::SUMMARY_REGION || address.category() == SummaryCategory::SUMMARY_REGION_2_REGION )
{
m_regionNumbers.insert( { address.regionNumber(), address } );
if ( address.regionNumber() != -1 )
{
m_regionNumbers.insert( { address.regionNumber(), address } );
}
}
if ( address.category() == SummaryCategory::SUMMARY_WELL_COMPLETION )
if ( address.category() == SummaryCategory::SUMMARY_WELL_CONNECTION )
{
auto wellNameAndCompletion = std::make_pair( wellName, address.blockAsString() );
m_wellCompletions.insert( wellNameAndCompletion );
auto wellNameAndConnection = std::make_pair( wellName, address.connectionAsString() );
m_wellConnections.insert( wellNameAndConnection );
}
else if ( address.category() == SummaryCategory::SUMMARY_WELL_SEGMENT )
{
@ -537,6 +567,11 @@ void RiaSummaryAddressAnalyzer::analyzeSingleAddress( const RifEclipseSummaryAdd
{
m_aquifers.insert( { address.aquiferNumber(), address } );
}
else if ( address.category() == SummaryCategory::SUMMARY_WELL_COMPLETION )
{
auto wellNameAndCompletion = std::make_pair( wellName, address.wellCompletionNumber() );
m_wellCompletionNumbers.insert( wellNameAndCompletion );
}
else if ( address.category() == SummaryCategory::SUMMARY_FIELD || address.category() == SummaryCategory::SUMMARY_MISC )
{
m_otherCategory.push_back( address );

View File

@ -59,10 +59,11 @@ public:
std::set<std::string> networkNames() const;
std::set<int> regionNumbers() const;
std::set<std::string> wellCompletions( const std::string& wellName ) const;
std::set<std::string> wellConnections( const std::string& wellName ) const;
std::set<int> wellSegmentNumbers( const std::string& wellName ) const;
std::set<std::string> blocks() const;
std::set<int> aquifers() const;
std::set<int> wellCompletionNumbers( const std::string& wellName ) const;
std::set<RifEclipseSummaryAddressDefines::SummaryCategory> categories() const;
std::vector<std::vector<RifEclipseSummaryAddress>> addressesGroupedByObject() const;
@ -102,8 +103,9 @@ private:
std::multimap<std::string, RifEclipseSummaryAddress> m_groupNames;
std::multimap<std::string, RifEclipseSummaryAddress> m_networkNames;
std::multimap<int, RifEclipseSummaryAddress> m_regionNumbers;
std::set<std::pair<std::string, std::string>> m_wellCompletions;
std::set<std::pair<std::string, std::string>> m_wellConnections;
std::set<std::pair<std::string, int>> m_wellSegmentNumbers;
std::set<std::pair<std::string, int>> m_wellCompletionNumbers;
std::multimap<std::string, RifEclipseSummaryAddress> m_blocks;
std::multimap<int, RifEclipseSummaryAddress> m_aquifers;

View File

@ -96,6 +96,14 @@ QString RiaDefines::summaryWell()
return "Well";
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
QString RiaDefines::summaryWellCompletion()
{
return "Completion";
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
@ -109,15 +117,15 @@ QString RiaDefines::summaryWellGroup()
//--------------------------------------------------------------------------------------------------
QString RiaDefines::summaryWellSegment()
{
return "Well Segment";
return "Segment";
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
QString RiaDefines::summaryCompletion()
QString RiaDefines::summaryWellConnection()
{
return "Completion";
return "Connection";
}
//--------------------------------------------------------------------------------------------------
@ -139,9 +147,9 @@ QString RiaDefines::summaryBlock()
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
QString RiaDefines::summaryLgrCompletion()
QString RiaDefines::summaryLgrConnection()
{
return "LGR Completion";
return "LGR Connection";
}
//--------------------------------------------------------------------------------------------------

View File

@ -48,12 +48,13 @@ QString summaryMisc();
QString summaryRegion();
QString summaryRegion2Region();
QString summaryWell();
QString summaryWellCompletion();
QString summaryWellGroup();
QString summaryWellSegment();
QString summaryCompletion();
QString summaryWellConnection();
QString summarySegment();
QString summaryBlock();
QString summaryLgrCompletion();
QString summaryLgrConnection();
QString summaryLgrWell();
QString summaryLgrBlock();
QString summaryCalculated();

View File

@ -28,6 +28,7 @@
#include "RifReaderEclipseOutput.h"
#include <cassert>
#include <regex>
#include <string>
#include <QDateTime>
@ -120,6 +121,7 @@ RifEclipseSummaryAddress addressFromErtSmSpecNode( const ecl::smspec_node& ertSu
int cellJ( -1 );
int cellK( -1 );
int aquiferNumber( -1 );
int wellCompletionNumber( -1 );
bool isErrorResult( false );
int id( -1 );
@ -168,7 +170,7 @@ RifEclipseSummaryAddress addressFromErtSmSpecNode( const ecl::smspec_node& ertSu
break;
case ECL_SMSPEC_COMPLETION_VAR:
{
sumCategory = RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION;
sumCategory = RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION;
wellName = stringFromPointer( ertSumVarNode.get_wgname() );
auto ijk = ertSumVarNode.get_ijk();
@ -190,7 +192,7 @@ RifEclipseSummaryAddress addressFromErtSmSpecNode( const ecl::smspec_node& ertSu
break;
case ECL_SMSPEC_LOCAL_COMPLETION_VAR:
{
sumCategory = RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION_LGR;
sumCategory = RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION_LGR;
wellName = stringFromPointer( ertSumVarNode.get_wgname() );
lgrName = stringFromPointer( ertSumVarNode.get_lgr_name() );
@ -249,6 +251,7 @@ RifEclipseSummaryAddress addressFromErtSmSpecNode( const ecl::smspec_node& ertSu
cellJ,
cellK,
aquiferNumber,
wellCompletionNumber,
isErrorResult,
id );
}
@ -317,11 +320,53 @@ void RifEclEclipseSummary::buildMetaData()
if ( m_ecl_SmSpec )
{
auto transformString = []( const std::string& input ) -> std::string
{
// Pattern 1: Handle "WGPRL__2:MY-WELL1-A5" format
// Matches text followed by __, number, colon, alphanumeric text, hyphen, alphanumeric
std::regex pattern1( "([A-Za-z]+)__([0-9]+):([A-Za-z0-9]+)-([A-Za-z0-9]+)" );
std::smatch matches;
if ( std::regex_search( input, matches, pattern1 ) )
{
return matches[1].str() + ":" + matches[3].str() + "-" + matches[4].str() + ":" + matches[2].str();
}
return input; // Return original string if pattern doesn't match
};
int varCount = ecl_smspec_num_nodes( m_ecl_SmSpec );
for ( int i = 0; i < varCount; i++ )
{
const ecl::smspec_node& ertSumVarNode = ecl_smspec_iget_node_w_node_index( m_ecl_SmSpec, i );
RifEclipseSummaryAddress addr = addressFromErtSmSpecNode( ertSumVarNode );
const ecl::smspec_node& ertSumVarNode = ecl_smspec_iget_node_w_node_index( m_ecl_SmSpec, i );
RifEclipseSummaryAddress addr = addressFromErtSmSpecNode( ertSumVarNode );
if ( ertSumVarNode.get_gen_key1() )
{
std::string completeVectorName = std::string( ertSumVarNode.get_gen_key1() );
completeVectorName = transformString( completeVectorName );
auto adrFromTextParsing = RifEclipseSummaryAddress::fromEclipseTextAddress( completeVectorName );
if ( addr != adrFromTextParsing )
{
auto ertAdrText = addr.toEclipseTextAddress();
auto adrFromText = adrFromTextParsing.toEclipseTextAddress();
QString detectedInconsiteny = QString( "Full text from ERT: %1, Address from ERT: %2, Address from text parsing: %3" )
.arg( QString::fromStdString( completeVectorName ) )
.arg( QString::fromStdString( ertAdrText ) )
.arg( QString::fromStdString( adrFromText ) );
RiaLogging::debug( detectedInconsiteny );
}
if ( adrFromTextParsing.isValid() )
{
addr = adrFromTextParsing;
}
}
m_allResultAddresses.insert( addr );
m_resultAddressToErtNodeIdx[addr] = i;
}

View File

@ -61,6 +61,10 @@ RifEclipseSummaryAddress::RifEclipseSummaryAddress( SummaryCategory category, st
m_name = identifiers[SummaryIdentifierType::INPUT_WELL_NAME];
break;
case SummaryCategory::SUMMARY_WELL_COMPLETION:
m_name = identifiers[SummaryIdentifierType::INPUT_WELL_NAME];
m_number0 = RiaStdStringTools::toInt( identifiers[SummaryIdentifierType::INPUT_WELL_COMPLETION_NUMBER] );
break;
case SummaryCategory::SUMMARY_WELL_CONNECTION:
m_name = identifiers[SummaryIdentifierType::INPUT_WELL_NAME];
setCellIjk( ijkTupleFromUiText( identifiers[SummaryIdentifierType::INPUT_CELL_IJK] ) );
break;
@ -68,7 +72,7 @@ RifEclipseSummaryAddress::RifEclipseSummaryAddress( SummaryCategory category, st
m_lgrName = identifiers[SummaryIdentifierType::INPUT_LGR_NAME];
m_name = identifiers[SummaryIdentifierType::INPUT_WELL_NAME];
break;
case SummaryCategory::SUMMARY_WELL_COMPLETION_LGR:
case SummaryCategory::SUMMARY_WELL_CONNECTION_LGR:
m_lgrName = identifiers[SummaryIdentifierType::INPUT_LGR_NAME];
m_name = identifiers[SummaryIdentifierType::INPUT_WELL_NAME];
setCellIjk( ijkTupleFromUiText( identifiers[SummaryIdentifierType::INPUT_CELL_IJK] ) );
@ -109,6 +113,7 @@ RifEclipseSummaryAddress::RifEclipseSummaryAddress( SummaryCategory category,
int cellJ,
int cellK,
int aquiferNumber,
int completionNumber,
bool isErrorResult,
int id )
: m_category( category )
@ -139,13 +144,17 @@ RifEclipseSummaryAddress::RifEclipseSummaryAddress( SummaryCategory category,
m_name = wellName;
break;
case SummaryCategory::SUMMARY_WELL_COMPLETION:
m_name = wellName;
m_number0 = completionNumber;
break;
case SummaryCategory::SUMMARY_WELL_CONNECTION:
m_name = wellName;
setCellIjk( cellI, cellJ, cellK );
break;
case SummaryCategory::SUMMARY_WELL_LGR:
m_name = wellName;
break;
case SummaryCategory::SUMMARY_WELL_COMPLETION_LGR:
case SummaryCategory::SUMMARY_WELL_CONNECTION_LGR:
m_name = wellName;
setCellIjk( cellI, cellJ, cellK );
break;
@ -329,13 +338,30 @@ RifEclipseSummaryAddress RifEclipseSummaryAddress::wellAddress( const std::strin
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RifEclipseSummaryAddress
RifEclipseSummaryAddress::wellCompletionAddress( const std::string& vectorName, const std::string& wellName, int i, int j, int k, int calculationId )
RifEclipseSummaryAddress RifEclipseSummaryAddress::wellCompletionAddress( const std::string& vectorName,
const std::string& wellName,
int completionNumber,
int calculationId /*= -1 */ )
{
RifEclipseSummaryAddress addr;
addr.m_category = SummaryCategory::SUMMARY_WELL_COMPLETION;
addr.m_vectorName = vectorName;
addr.m_name = wellName;
addr.m_number0 = completionNumber;
addr.m_id = calculationId;
return addr;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
RifEclipseSummaryAddress
RifEclipseSummaryAddress::wellConnectionAddress( const std::string& vectorName, const std::string& wellName, int i, int j, int k, int calculationId )
{
RifEclipseSummaryAddress addr;
addr.m_category = SummaryCategory::SUMMARY_WELL_CONNECTION;
addr.m_vectorName = vectorName;
addr.m_name = wellName;
addr.setCellIjk( i, j, k );
addr.m_id = calculationId;
return addr;
@ -370,7 +396,7 @@ RifEclipseSummaryAddress RifEclipseSummaryAddress::wellCompletionLgrAddress( con
int calculationId )
{
RifEclipseSummaryAddress addr;
addr.m_category = SummaryCategory::SUMMARY_WELL_COMPLETION_LGR;
addr.m_category = SummaryCategory::SUMMARY_WELL_CONNECTION_LGR;
addr.m_vectorName = vectorName;
addr.m_lgrName = lgrName;
addr.m_name = wellName;
@ -483,9 +509,9 @@ std::string RifEclipseSummaryAddress::generateStringFromAddresses( const std::ve
//--------------------------------------------------------------------------------------------------
bool RifEclipseSummaryAddress::isDependentOnWellName( SummaryCategory category )
{
return ( category == SummaryCategory::SUMMARY_WELL || category == SummaryCategory::SUMMARY_WELL_COMPLETION ||
category == SummaryCategory::SUMMARY_WELL_COMPLETION_LGR || category == SummaryCategory::SUMMARY_WELL_LGR ||
category == SummaryCategory::SUMMARY_WELL_SEGMENT );
return ( category == SummaryCategory::SUMMARY_WELL || category == SummaryCategory::SUMMARY_WELL_CONNECTION ||
category == SummaryCategory::SUMMARY_WELL_CONNECTION_LGR || category == SummaryCategory::SUMMARY_WELL_LGR ||
category == SummaryCategory::SUMMARY_WELL_SEGMENT || category == SummaryCategory::SUMMARY_WELL_COMPLETION );
}
//--------------------------------------------------------------------------------------------------
@ -554,6 +580,14 @@ std::string RifEclipseSummaryAddress::wellName() const
return isDependentOnWellName( m_category ) ? m_name : std::string();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
int RifEclipseSummaryAddress::wellCompletionNumber() const
{
return m_number0;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
@ -679,7 +713,14 @@ std::string RifEclipseSummaryAddress::itemUiText() const
case SummaryCategory::SUMMARY_WELL_COMPLETION:
{
text += wellName();
text += ":" + blockAsString();
text += ":";
text += std::to_string( wellCompletionNumber() );
}
break;
case SummaryCategory::SUMMARY_WELL_CONNECTION:
{
text += wellName();
text += ":" + connectionAsString();
}
break;
case SummaryCategory::SUMMARY_WELL_LGR:
@ -689,13 +730,13 @@ std::string RifEclipseSummaryAddress::itemUiText() const
text += wellName();
}
break;
case SummaryCategory::SUMMARY_WELL_COMPLETION_LGR:
case SummaryCategory::SUMMARY_WELL_CONNECTION_LGR:
{
text += lgrName();
text += ":";
text += wellName();
text += ":";
text += blockAsString();
text += connectionAsString();
}
break;
case SummaryCategory::SUMMARY_WELL_SEGMENT:
@ -762,6 +803,8 @@ std::string RifEclipseSummaryAddress::addressComponentUiText( RifEclipseSummaryA
return m_lgrName;
case SummaryIdentifierType::INPUT_SEGMENT_NUMBER:
return std::to_string( wellSegmentNumber() );
case SummaryIdentifierType::INPUT_WELL_COMPLETION_NUMBER:
return std::to_string( wellCompletionNumber() );
case SummaryIdentifierType::INPUT_AQUIFER_NUMBER:
return std::to_string( aquiferNumber() );
case SummaryIdentifierType::INPUT_VECTOR_NAME:
@ -813,6 +856,10 @@ bool RifEclipseSummaryAddress::isValid() const
return !m_name.empty();
case SummaryCategory::SUMMARY_WELL_COMPLETION:
if ( m_name.empty() ) return false;
return m_number0 != -1;
case SummaryCategory::SUMMARY_WELL_CONNECTION:
if ( m_name.empty() ) return false;
if ( m_number0 == -1 ) return false;
if ( m_number1 == -1 ) return false;
@ -823,7 +870,7 @@ bool RifEclipseSummaryAddress::isValid() const
if ( m_lgrName.empty() ) return false;
return !m_name.empty();
case SummaryCategory::SUMMARY_WELL_COMPLETION_LGR:
case SummaryCategory::SUMMARY_WELL_CONNECTION_LGR:
if ( m_lgrName.empty() ) return false;
if ( m_name.empty() ) return false;
if ( m_number0 == -1 ) return false;
@ -948,6 +995,14 @@ void RifEclipseSummaryAddress::setWellSegmentNumber( int segment )
m_number0 = segment;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
void RifEclipseSummaryAddress::setWellCompletionNumber( int completionNumber )
{
m_number0 = completionNumber;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
@ -1011,16 +1066,24 @@ RifEclipseSummaryAddress RifEclipseSummaryAddress::fromTokens( const std::vector
std::string token1;
std::string token2;
int intValue0 = 0;
int intValue1 = 0;
int intValue2 = 0;
int intValue0 = -1;
int intValue1 = -1;
int intValue2 = -1;
vectorName = tokens[0];
if ( tokens.size() > 1 ) token1 = tokens[1];
if ( tokens.size() > 2 ) token2 = tokens[2];
SummaryCategory category = RiuSummaryQuantityNameInfoProvider::instance()->identifyCategory( vectorName );
SummaryCategory category = SummaryCategory::SUMMARY_INVALID;
if ( ( tokens.size() == 3 ) && ( vectorName.starts_with( 'W' ) ) )
{
category = SummaryCategory::SUMMARY_WELL_COMPLETION;
}
else
{
category = RiuSummaryQuantityNameInfoProvider::instance()->identifyCategory( vectorName );
}
switch ( category )
{
@ -1081,10 +1144,21 @@ RifEclipseSummaryAddress RifEclipseSummaryAddress::fromTokens( const std::vector
break;
case SummaryCategory::SUMMARY_WELL:
if ( !token1.empty() ) return wellAddress( vectorName, token1 );
{
auto wellName = token1;
if ( !wellName.empty() ) return wellAddress( vectorName, wellName );
break;
}
case SummaryCategory::SUMMARY_WELL_COMPLETION:
{
RiaStdStringTools::toInt( token2, intValue0 );
if ( !token1.empty() ) return wellCompletionAddress( vectorName, token1, intValue0 );
break;
}
case SummaryCategory::SUMMARY_WELL_CONNECTION:
if ( !token2.empty() )
{
auto ijk = RiaStdStringTools::splitString( token2, ',' );
@ -1094,7 +1168,7 @@ RifEclipseSummaryAddress RifEclipseSummaryAddress::fromTokens( const std::vector
RiaStdStringTools::toInt( ijk[1], intValue1 );
RiaStdStringTools::toInt( ijk[2], intValue2 );
return wellCompletionAddress( vectorName, token1, intValue0, intValue1, intValue2 );
return wellConnectionAddress( vectorName, token1, intValue0, intValue1, intValue2 );
}
}
break;
@ -1103,7 +1177,7 @@ RifEclipseSummaryAddress RifEclipseSummaryAddress::fromTokens( const std::vector
if ( !token1.empty() && !token2.empty() ) return wellLgrAddress( vectorName, token1, token2 );
break;
case SummaryCategory::SUMMARY_WELL_COMPLETION_LGR:
case SummaryCategory::SUMMARY_WELL_CONNECTION_LGR:
if ( tokens.size() > 2 )
{
const auto& token3 = tokens[3];
@ -1184,8 +1258,9 @@ bool RifEclipseSummaryAddress::isValidEclipseCategory() const
case SummaryCategory::SUMMARY_GROUP:
case SummaryCategory::SUMMARY_WELL:
case SummaryCategory::SUMMARY_WELL_COMPLETION:
case SummaryCategory::SUMMARY_WELL_CONNECTION:
case SummaryCategory::SUMMARY_WELL_LGR:
case SummaryCategory::SUMMARY_WELL_COMPLETION_LGR:
case SummaryCategory::SUMMARY_WELL_CONNECTION_LGR:
case SummaryCategory::SUMMARY_WELL_SEGMENT:
case SummaryCategory::SUMMARY_BLOCK:
case SummaryCategory::SUMMARY_BLOCK_LGR:
@ -1223,6 +1298,14 @@ std::string RifEclipseSummaryAddress::blockAsString() const
return std::to_string( cellI() ) + "," + std::to_string( cellJ() ) + "," + std::to_string( cellK() );
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
std::string RifEclipseSummaryAddress::connectionAsString() const
{
return blockAsString();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------

View File

@ -50,6 +50,7 @@ public:
int cellJ,
int cellK,
int aquiferNumber,
int completionNumber,
bool isErrorResult,
int id );
@ -69,9 +70,11 @@ public:
regionToRegionAddress( const std::string& vectorName, int regionNumber, int region2Number, int calculationId = -1 );
static RifEclipseSummaryAddress groupAddress( const std::string& vectorName, const std::string& groupName, int calculationId = -1 );
static RifEclipseSummaryAddress wellAddress( const std::string& vectorName, const std::string& wellName, int calculationId = -1 );
static RifEclipseSummaryAddress
wellCompletionAddress( const std::string& vectorName, const std::string& wellName, int completionNumber, int calculationId = -1 );
static RifEclipseSummaryAddress
wellCompletionAddress( const std::string& vectorName, const std::string& wellName, int i, int j, int k, int calculationId = -1 );
wellConnectionAddress( const std::string& vectorName, const std::string& wellName, int i, int j, int k, int calculationId = -1 );
static RifEclipseSummaryAddress
wellLgrAddress( const std::string& vectorName, const std::string& lgrName, const std::string& wellName, int calculationId = -1 );
static RifEclipseSummaryAddress wellCompletionLgrAddress( const std::string& vectorName,
@ -109,6 +112,7 @@ public:
std::string groupName() const;
std::string networkName() const;
std::string wellName() const;
int wellCompletionNumber() const;
int wellSegmentNumber() const;
std::string lgrName() const;
int cellI() const;
@ -117,6 +121,7 @@ public:
int aquiferNumber() const;
int id() const;
std::string blockAsString() const;
std::string connectionAsString() const;
std::string ensembleStatisticsVectorName() const;
@ -139,6 +144,7 @@ public:
void setAquiferNumber( int aquiferNumber );
void setCellIjk( const std::string& uiText );
void setWellSegmentNumber( int segment );
void setWellCompletionNumber( int completionNumber );
void setAsErrorResult();
bool isErrorResult() const;

View File

@ -39,8 +39,9 @@ enum class SummaryCategory
SUMMARY_GROUP,
SUMMARY_WELL,
SUMMARY_WELL_COMPLETION,
SUMMARY_WELL_CONNECTION,
SUMMARY_WELL_LGR,
SUMMARY_WELL_COMPLETION_LGR,
SUMMARY_WELL_CONNECTION_LGR,
SUMMARY_WELL_SEGMENT,
SUMMARY_BLOCK,
SUMMARY_BLOCK_LGR,
@ -54,6 +55,7 @@ enum class SummaryIdentifierType
INPUT_REGION_NUMBER,
INPUT_REGION_2_REGION,
INPUT_WELL_NAME,
INPUT_WELL_COMPLETION_NUMBER,
INPUT_GROUP_NAME,
INPUT_NETWORK_NAME,
INPUT_CELL_IJK,

View File

@ -179,7 +179,8 @@ RifEclipseSummaryAddress RifEclipseUserDataKeywordTools::makeAndFillAddress( con
std::string groupName;
std::string networkName;
std::string wellName;
int wellSegmentNumber = -1;
int wellSegmentNumber = -1;
int wellCompletionNumber = -1;
std::string lgrName;
int cellI = -1;
int cellJ = -1;
@ -230,7 +231,7 @@ RifEclipseSummaryAddress RifEclipseUserDataKeywordTools::makeAndFillAddress( con
}
break;
}
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION:
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION:
{
if ( columnHeaderText.size() > 1 )
{
@ -248,7 +249,7 @@ RifEclipseSummaryAddress RifEclipseUserDataKeywordTools::makeAndFillAddress( con
lgrName = columnHeaderText[1];
}
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION_LGR:
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION_LGR:
if ( columnHeaderText.size() > 2 )
{
wellName = columnHeaderText[0];
@ -257,6 +258,13 @@ RifEclipseSummaryAddress RifEclipseUserDataKeywordTools::makeAndFillAddress( con
RifEclipseUserDataKeywordTools::extractThreeInts( &cellI, &cellJ, &cellK, columnHeaderText[2] );
}
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION:
if ( columnHeaderText.size() > 1 )
{
wellName = columnHeaderText[0];
wellCompletionNumber = RiaStdStringTools::toInt( columnHeaderText[1] );
}
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_SEGMENT:
if ( columnHeaderText.size() > 1 )
{
@ -295,6 +303,7 @@ RifEclipseSummaryAddress RifEclipseUserDataKeywordTools::makeAndFillAddress( con
cellJ,
cellK,
aquiferNumber,
wellCompletionNumber,
isErrorResult,
id );
}

View File

@ -465,3 +465,28 @@ std::pair<std::set<RifEclipseSummaryAddress>, std::map<RifEclipseSummaryAddress,
return { addresses, addressToKeywordMap };
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
SummaryCategory RifOpmCommonSummaryTools::categoryFromKeyword( const std::string& keyword )
{
auto opmCategory = Opm::EclIO::SummaryNode::category_from_keyword( keyword );
switch ( opmCategory )
{
case Opm::EclIO::SummaryNode::Category::Aquifer:
return SummaryCategory::SUMMARY_AQUIFER;
case Opm::EclIO::SummaryNode::Category::Block:
return SummaryCategory::SUMMARY_BLOCK;
case Opm::EclIO::SummaryNode::Category::Connection:
return SummaryCategory::SUMMARY_WELL_CONNECTION;
case Opm::EclIO::SummaryNode::Category::Completion:
return SummaryCategory::SUMMARY_WELL_COMPLETION;
case Opm::EclIO::SummaryNode::Category::Field:
return SummaryCategory::SUMMARY_FIELD;
case Opm::EclIO::SummaryNode::Category::Group:
return SummaryCategory::SUMMARY_GROUP;
}
return SummaryCategory::SUMMARY_INVALID;
}

View File

@ -44,15 +44,17 @@ namespace EclIO
class RiaThreadSafeLogger;
class RifOpmCommonSummaryTools
namespace RifOpmCommonSummaryTools
{
public:
static std::tuple<std::set<RifEclipseSummaryAddress>, std::map<RifEclipseSummaryAddress, size_t>, std::map<RifEclipseSummaryAddress, std::string>>
buildAddressesSmspecAndKeywordMap( const Opm::EclIO::ESmry* summaryFile );
std::tuple<std::set<RifEclipseSummaryAddress>, std::map<RifEclipseSummaryAddress, size_t>, std::map<RifEclipseSummaryAddress, std::string>>
buildAddressesSmspecAndKeywordMap( const Opm::EclIO::ESmry* summaryFile );
static std::pair<std::set<RifEclipseSummaryAddress>, std::map<RifEclipseSummaryAddress, std::string>>
buildAddressesAndKeywordMap( const std::vector<std::string>& keywords );
};
std::pair<std::set<RifEclipseSummaryAddress>, std::map<RifEclipseSummaryAddress, std::string>>
buildAddressesAndKeywordMap( const std::vector<std::string>& keywords );
SummaryCategory categoryFromKeyword( const std::string& keyword );
}; // namespace RifOpmCommonSummaryTools
//==================================================================================================
//

View File

@ -171,6 +171,7 @@ RifEclipseSummaryAddress RifReaderObservedData::address( const QString&
int cellJ( -1 );
int cellK( -1 );
int aquiferNumber( -1 );
int wellCompletionNumber( -1 );
bool isErrorResult( false );
int id( -1 );
@ -202,6 +203,7 @@ RifEclipseSummaryAddress RifReaderObservedData::address( const QString&
cellJ,
cellK,
aquiferNumber,
wellCompletionNumber,
isErrorResult,
id );
}

View File

@ -137,8 +137,19 @@ bool RimDataSourceSteppingTools::updateAddressIfMatching( const QVariant&
return true;
}
}
else if ( category == RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION )
{
int oldInt = oldValue.toInt();
int newInt = newValue.toInt();
if ( adr.wellCompletionNumber() == oldInt )
{
adr.setWellCompletionNumber( newInt );
return true;
}
}
else if ( category == RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_BLOCK ||
category == RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION )
category == RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION )
{
std::string oldString = oldValue.toString().toStdString();
std::string newString = newValue.toString().toStdString();

View File

@ -249,13 +249,19 @@ void RimSummaryCalculation::substituteVariables( std::vector<SummaryCalculationV
newValue = QString::fromStdString( address.groupName() );
isHandledBySteppingTools = true;
}
else if ( category == RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION )
{
oldValue = firstVariable.summaryAddress.wellCompletionNumber();
newValue = address.wellCompletionNumber();
isHandledBySteppingTools = true;
}
else if ( category == RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_AQUIFER )
{
oldValue = firstVariable.summaryAddress.aquiferNumber();
newValue = address.aquiferNumber();
isHandledBySteppingTools = true;
}
else if ( category == RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION ||
else if ( category == RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION ||
category == RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_BLOCK )
{
oldValue = QString::fromStdString( firstVariable.summaryAddress.blockAsString() );

View File

@ -119,9 +119,17 @@ bool RimMultiSummaryPlotNameHelper::isSegmentInTitle() const
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
bool RimMultiSummaryPlotNameHelper::isCompletionInTitle() const
bool RimMultiSummaryPlotNameHelper::isWellCompletionInTitle() const
{
return std::any_of( m_nameHelpers.begin(), m_nameHelpers.end(), []( auto nameHelper ) { return nameHelper->isCompletionInTitle(); } );
return std::any_of( m_nameHelpers.begin(), m_nameHelpers.end(), []( auto nameHelper ) { return nameHelper->isWellCompletionInTitle(); } );
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
bool RimMultiSummaryPlotNameHelper::isConnectionInTitle() const
{
return std::any_of( m_nameHelpers.begin(), m_nameHelpers.end(), []( auto nameHelper ) { return nameHelper->isConnectionInTitle(); } );
}
//--------------------------------------------------------------------------------------------------
@ -247,11 +255,24 @@ std::string RimMultiSummaryPlotNameHelper::titleSegment() const
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
std::string RimMultiSummaryPlotNameHelper::titleCompletion() const
std::string RimMultiSummaryPlotNameHelper::titleWellCompletion() const
{
for ( auto nameHelper : m_nameHelpers )
{
if ( nameHelper->isCompletionInTitle() ) return nameHelper->titleCompletion();
if ( nameHelper->isWellCompletionInTitle() ) return nameHelper->titleWellCompletion();
}
return "";
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
std::string RimMultiSummaryPlotNameHelper::titleConnection() const
{
for ( auto nameHelper : m_nameHelpers )
{
if ( nameHelper->isConnectionInTitle() ) return nameHelper->titleConnection();
}
return "";

View File

@ -38,7 +38,8 @@ public:
bool isCaseInTitle() const override;
bool isBlockInTitle() const override;
bool isSegmentInTitle() const override;
bool isCompletionInTitle() const override;
bool isWellCompletionInTitle() const override;
bool isConnectionInTitle() const override;
std::vector<std::string> vectorNames() const override;
QString caseName() const override;
@ -50,7 +51,8 @@ public:
std::string titleRegion() const override;
std::string titleBlock() const override;
std::string titleSegment() const override;
std::string titleCompletion() const override;
std::string titleWellCompletion() const override;
std::string titleConnection() const override;
size_t numberOfCases() const override;

View File

@ -37,8 +37,9 @@ void caf::AppEnum<RifEclipseSummaryAddressDefines::SummaryCategory>::setUp()
addItem( RifAdr::SUMMARY_REGION_2_REGION, "SUMMARY_REGION_2_REGION", RiaDefines::summaryRegion2Region() );
addItem( RifAdr::SUMMARY_GROUP, "SUMMARY_WELL_GROUP", RiaDefines::summaryWellGroup() );
addItem( RifAdr::SUMMARY_WELL, "SUMMARY_WELL", RiaDefines::summaryWell() );
addItem( RifAdr::SUMMARY_WELL_COMPLETION, "SUMMARY_WELL_COMPLETION", RiaDefines::summaryCompletion() );
addItem( RifAdr::SUMMARY_WELL_COMPLETION_LGR, "SUMMARY_WELL_COMPLETION_LGR", RiaDefines::summaryLgrCompletion() );
addItem( RifAdr::SUMMARY_WELL_COMPLETION, "SUMMARY_WELL_COMPLETION", RiaDefines::summaryWellCompletion() );
addItem( RifAdr::SUMMARY_WELL_CONNECTION, "SUMMARY_WELL_CONNECTION", RiaDefines::summaryWellConnection() );
addItem( RifAdr::SUMMARY_WELL_CONNECTION_LGR, "SUMMARY_WELL_CONNECTION_LGR", RiaDefines::summaryLgrConnection() );
addItem( RifAdr::SUMMARY_WELL_LGR, "SUMMARY_WELL_LGR", RiaDefines::summaryLgrWell() );
addItem( RifAdr::SUMMARY_WELL_SEGMENT, "SUMMARY_SEGMENT", RiaDefines::summarySegment() );
addItem( RifAdr::SUMMARY_BLOCK, "SUMMARY_BLOCK", RiaDefines::summaryBlock() );
@ -72,22 +73,24 @@ RimSummaryAddress::RimSummaryAddress()
CAF_PDM_InitFieldNoDefault( &m_cellJ, "SummaryCellJ", "J" );
CAF_PDM_InitFieldNoDefault( &m_cellK, "SummaryCellK", "K" );
CAF_PDM_InitFieldNoDefault( &m_aquiferNumber, "SummaryAquifer", "Aquifer" );
CAF_PDM_InitFieldNoDefault( &m_wellCompletionNumber, "SummaryWellCompletionNumber", "Well Completion Number" );
CAF_PDM_InitFieldNoDefault( &m_isErrorResult, "IsErrorResult", "Is Error Result" );
CAF_PDM_InitFieldNoDefault( &m_calculationId, "CalculationId", "Calculation Id" );
CAF_PDM_InitField( &m_caseId, "CaseId", -1, "CaseId" );
CAF_PDM_InitField( &m_ensembleId, "EnsembleId", -1, "EnsembleId" );
m_category = RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_INVALID;
m_regionNumber = -1;
m_regionNumber2 = -1;
m_wellSegmentNumber = -1;
m_cellI = -1;
m_cellJ = -1;
m_cellK = -1;
m_aquiferNumber = -1;
m_isErrorResult = false;
m_calculationId = -1;
m_category = RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_INVALID;
m_regionNumber = -1;
m_regionNumber2 = -1;
m_wellSegmentNumber = -1;
m_cellI = -1;
m_cellJ = -1;
m_cellK = -1;
m_aquiferNumber = -1;
m_wellCompletionNumber = -1;
m_isErrorResult = false;
m_calculationId = -1;
}
//--------------------------------------------------------------------------------------------------
@ -115,17 +118,18 @@ RimSummaryAddress*
//--------------------------------------------------------------------------------------------------
void RimSummaryAddress::setAddress( const RifEclipseSummaryAddress& addr )
{
m_category = addr.category();
m_vectorName = addr.vectorName().c_str();
m_regionNumber = addr.regionNumber();
m_regionNumber2 = addr.regionNumber2();
m_groupName = addr.groupName().c_str();
m_networkName = addr.networkName().c_str();
m_wellName = addr.wellName().c_str();
m_wellSegmentNumber = addr.wellSegmentNumber();
m_lgrName = addr.lgrName().c_str();
m_aquiferNumber = addr.aquiferNumber();
m_isErrorResult = addr.isErrorResult();
m_category = addr.category();
m_vectorName = addr.vectorName().c_str();
m_regionNumber = addr.regionNumber();
m_regionNumber2 = addr.regionNumber2();
m_groupName = addr.groupName().c_str();
m_networkName = addr.networkName().c_str();
m_wellName = addr.wellName().c_str();
m_wellSegmentNumber = addr.wellSegmentNumber();
m_lgrName = addr.lgrName().c_str();
m_aquiferNumber = addr.aquiferNumber();
m_wellCompletionNumber = addr.wellCompletionNumber();
m_isErrorResult = addr.isErrorResult();
m_cellI = addr.cellI();
m_cellJ = addr.cellJ();
@ -154,6 +158,7 @@ RifEclipseSummaryAddress RimSummaryAddress::address() const
m_cellJ(),
m_cellK(),
m_aquiferNumber,
m_wellCompletionNumber(),
m_isErrorResult,
m_calculationId );
}

View File

@ -79,6 +79,7 @@ private:
caf::PdmField<int> m_cellJ;
caf::PdmField<int> m_cellK;
caf::PdmField<int> m_aquiferNumber;
caf::PdmField<int> m_wellCompletionNumber;
caf::PdmField<bool> m_isErrorResult;
caf::PdmField<int> m_calculationId;
caf::PdmField<int> m_caseId;

View File

@ -47,9 +47,10 @@ void caf::AppEnum<RimSummaryAddressCollection::CollectionContentType>::setUp()
addItem( CollectionContentType::AQUIFER, "AQUIFER", RiaDefines::summaryAquifer() );
addItem( CollectionContentType::NETWORK, "NETWORK", RiaDefines::summaryNetwork() );
addItem( CollectionContentType::REGION_2_REGION, "REGION_2_REGION", RiaDefines::summaryRegion2Region() );
addItem( CollectionContentType::WELL_COMPLETION, "WELL_COMPLETION", RiaDefines::summaryCompletion() );
addItem( CollectionContentType::WELL_CONNECTION, "WELL_CONNECTION", RiaDefines::summaryWellConnection() );
addItem( CollectionContentType::WELL_COMPLETION, "WELL_COMPLETION", RiaDefines::summaryWellCompletion() );
addItem( CollectionContentType::WELL_LGR, "WELL_LGR", RiaDefines::summaryLgrWell() );
addItem( CollectionContentType::WELL_COMPLETION_LGR, "WELL_COMPLETION_LGR", RiaDefines::summaryLgrCompletion() );
addItem( CollectionContentType::WELL_CONNECTION_LGR, "WELL_CONNECTION_LGR", RiaDefines::summaryLgrConnection() );
addItem( CollectionContentType::WELL_SEGMENT, "WELL_SEGMENT", RiaDefines::summaryWellSegment() );
addItem( CollectionContentType::BLOCK_LGR, "BLOCK_LGR", RiaDefines::summaryLgrBlock() );
addItem( CollectionContentType::CALCULATED, "CALCULATED", RiaDefines::summaryCalculated() );
@ -82,12 +83,12 @@ RifEclipseSummaryAddressDefines::SummaryCategory RimSummaryAddressCollection::co
return SummaryCategory::SUMMARY_NETWORK;
case CollectionContentType::REGION_2_REGION:
return SummaryCategory::SUMMARY_REGION_2_REGION;
case CollectionContentType::WELL_COMPLETION:
return SummaryCategory::SUMMARY_WELL_COMPLETION;
case CollectionContentType::WELL_CONNECTION:
return SummaryCategory::SUMMARY_WELL_CONNECTION;
case CollectionContentType::WELL_LGR:
return SummaryCategory::SUMMARY_WELL_LGR;
case CollectionContentType::WELL_COMPLETION_LGR:
return SummaryCategory::SUMMARY_WELL_COMPLETION_LGR;
case CollectionContentType::WELL_CONNECTION_LGR:
return SummaryCategory::SUMMARY_WELL_CONNECTION_LGR;
case CollectionContentType::WELL_SEGMENT:
return SummaryCategory::SUMMARY_WELL_SEGMENT;
case CollectionContentType::BLOCK:
@ -192,18 +193,16 @@ void RimSummaryAddressCollection::addToSubfolder( QString
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
void RimSummaryAddressCollection::addToSubfolderTree( std::vector<QString> folders,
CollectionContentType folderType,
const RifEclipseSummaryAddress& address,
int caseId,
int ensembleId )
void RimSummaryAddressCollection::addToSubfolderTree( std::vector<std::pair<QString, CollectionContentType>> folders,
const RifEclipseSummaryAddress& address,
int caseId,
int ensembleId )
{
RimSummaryAddressCollection* thefolder = this;
for ( auto& subfoldername : folders )
for ( auto& [subfoldername, folderType] : folders )
{
thefolder = thefolder->getOrCreateSubfolder( subfoldername, folderType );
}
thefolder->setContentType( folderType );
thefolder->addAddress( address, caseId, ensembleId );
}
@ -214,21 +213,22 @@ void RimSummaryAddressCollection::updateFolderStructure( const std::set<RifEclip
{
if ( addresses.empty() ) return;
auto* fields = getOrCreateSubfolder( CollectionContentType::FIELD );
auto* groups = getOrCreateSubfolder( CollectionContentType::GROUP_FOLDER );
auto* wells = getOrCreateSubfolder( CollectionContentType::WELL_FOLDER );
auto* aquifer = getOrCreateSubfolder( CollectionContentType::AQUIFER );
auto* networks = getOrCreateSubfolder( CollectionContentType::NETWORK_FOLDER );
auto* misc = getOrCreateSubfolder( CollectionContentType::MISC );
auto* regions = getOrCreateSubfolder( CollectionContentType::REGION_FOLDER );
auto* region2region = getOrCreateSubfolder( CollectionContentType::REGION_2_REGION );
auto* completion = getOrCreateSubfolder( CollectionContentType::WELL_COMPLETION );
auto* segment = getOrCreateSubfolder( CollectionContentType::WELL_SEGMENT );
auto* blocks = getOrCreateSubfolder( CollectionContentType::BLOCK );
auto* lgrwell = getOrCreateSubfolder( CollectionContentType::WELL_LGR );
auto* lgrcompletion = getOrCreateSubfolder( CollectionContentType::WELL_COMPLETION_LGR );
auto* lgrblock = getOrCreateSubfolder( CollectionContentType::BLOCK_LGR );
auto* imported = getOrCreateSubfolder( CollectionContentType::IMPORTED );
auto* fields = getOrCreateSubfolder( CollectionContentType::FIELD );
auto* groups = getOrCreateSubfolder( CollectionContentType::GROUP_FOLDER );
auto* wells = getOrCreateSubfolder( CollectionContentType::WELL_FOLDER );
auto* aquifer = getOrCreateSubfolder( CollectionContentType::AQUIFER );
auto* networks = getOrCreateSubfolder( CollectionContentType::NETWORK_FOLDER );
auto* misc = getOrCreateSubfolder( CollectionContentType::MISC );
auto* regions = getOrCreateSubfolder( CollectionContentType::REGION_FOLDER );
auto* region2region = getOrCreateSubfolder( CollectionContentType::REGION_2_REGION );
auto* segment = getOrCreateSubfolder( CollectionContentType::WELL_SEGMENT );
auto* wellCompletions = getOrCreateSubfolder( CollectionContentType::WELL_COMPLETION );
auto* wellConnection = getOrCreateSubfolder( CollectionContentType::WELL_CONNECTION );
auto* blocks = getOrCreateSubfolder( CollectionContentType::BLOCK );
auto* lgrwell = getOrCreateSubfolder( CollectionContentType::WELL_LGR );
auto* lgrConnection = getOrCreateSubfolder( CollectionContentType::WELL_CONNECTION_LGR );
auto* lgrblock = getOrCreateSubfolder( CollectionContentType::BLOCK_LGR );
auto* imported = getOrCreateSubfolder( CollectionContentType::IMPORTED );
// Sort addresses to have calculated results last per category
std::vector<RifEclipseSummaryAddress> sortedAddresses;
@ -252,6 +252,7 @@ void RimSummaryAddressCollection::updateFolderStructure( const std::set<RifEclip
if ( a.cellI() != b.cellI() ) return a.cellI() < b.cellI();
if ( a.wellSegmentNumber() != b.wellSegmentNumber() ) return a.wellSegmentNumber() < b.wellSegmentNumber();
if ( a.aquiferNumber() != b.aquiferNumber() ) return a.aquiferNumber() < b.aquiferNumber();
if ( a.wellCompletionNumber() != b.wellCompletionNumber() ) return a.wellCompletionNumber() < b.wellCompletionNumber();
if ( a.isErrorResult() != b.isErrorResult() ) return !a.isErrorResult();
// Calculated results are sorted last.
@ -299,18 +300,27 @@ void RimSummaryAddressCollection::updateFolderStructure( const std::set<RifEclip
wells->addToSubfolder( QString::fromStdString( address.wellName() ), CollectionContentType::WELL, address, caseId, ensembleId );
break;
case SummaryCategory::SUMMARY_WELL_CONNECTION:
wellConnection->addToSubfolderTree( { { QString::fromStdString( address.wellName() ), CollectionContentType::WELL },
{ QString::fromStdString( address.connectionAsString() ),
CollectionContentType::WELL_CONNECTION } },
address,
caseId,
ensembleId );
break;
case SummaryCategory::SUMMARY_WELL_COMPLETION:
completion->addToSubfolderTree( { QString::fromStdString( address.wellName() ),
QString::fromStdString( address.blockAsString() ) },
CollectionContentType::WELL_COMPLETION,
address,
caseId,
ensembleId );
wellCompletions->addToSubfolderTree( { { QString::fromStdString( address.wellName() ), CollectionContentType::WELL },
{ QString::number( address.wellCompletionNumber() ),
CollectionContentType::WELL_COMPLETION } },
address,
caseId,
ensembleId );
break;
case SummaryCategory::SUMMARY_WELL_SEGMENT:
segment->addToSubfolderTree( { QString::fromStdString( address.wellName() ), QString::number( address.wellSegmentNumber() ) },
CollectionContentType::WELL_SEGMENT,
segment->addToSubfolderTree( { { QString::fromStdString( address.wellName() ), CollectionContentType::WELL },
{ QString::number( address.wellSegmentNumber() ), CollectionContentType::WELL_SEGMENT } },
address,
caseId,
ensembleId );
@ -321,26 +331,25 @@ void RimSummaryAddressCollection::updateFolderStructure( const std::set<RifEclip
break;
case SummaryCategory::SUMMARY_WELL_LGR:
lgrwell->addToSubfolderTree( { QString::fromStdString( address.lgrName() ), QString::fromStdString( address.wellName() ) },
CollectionContentType::WELL_LGR,
lgrwell->addToSubfolderTree( { { QString::fromStdString( address.lgrName() ), CollectionContentType::WELL_LGR },
{ QString::fromStdString( address.wellName() ), CollectionContentType::WELL } },
address,
caseId,
ensembleId );
break;
case SummaryCategory::SUMMARY_WELL_COMPLETION_LGR:
lgrcompletion->addToSubfolderTree( { QString::fromStdString( address.lgrName() ),
QString::fromStdString( address.wellName() ),
QString::fromStdString( address.blockAsString() ) },
CollectionContentType::WELL_COMPLETION_LGR,
case SummaryCategory::SUMMARY_WELL_CONNECTION_LGR:
lgrConnection->addToSubfolderTree( { { QString::fromStdString( address.lgrName() ), CollectionContentType::WELL_LGR },
{ QString::fromStdString( address.wellName() ), CollectionContentType::WELL },
{ QString::fromStdString( address.blockAsString() ), CollectionContentType::BLOCK } },
address,
caseId,
ensembleId );
break;
case SummaryCategory::SUMMARY_BLOCK_LGR:
lgrblock->addToSubfolderTree( { QString::fromStdString( address.lgrName() ), QString::fromStdString( address.blockAsString() ) },
CollectionContentType::BLOCK_LGR,
lgrblock->addToSubfolderTree( { { QString::fromStdString( address.lgrName() ), CollectionContentType::WELL_LGR },
{ QString::fromStdString( address.blockAsString() ), CollectionContentType::BLOCK } },
address,
caseId,
ensembleId );
@ -556,6 +565,8 @@ QString RimSummaryAddressCollection::iconResourceText() const
return ":/summary/components/images/misc.svg";
case RimSummaryAddressCollection::CollectionContentType::WELL_FOLDER:
return ":/summary/components/images/well.svg";
case RimSummaryAddressCollection::CollectionContentType::WELL_COMPLETION:
return ":/summary/components/images/well-completion-01.svg";
case RimSummaryAddressCollection::CollectionContentType::GROUP_FOLDER:
return ":/summary/components/images/group.svg";
case RimSummaryAddressCollection::CollectionContentType::NETWORK_FOLDER:
@ -572,12 +583,12 @@ QString RimSummaryAddressCollection::iconResourceText() const
return ":/summary/components/images/network.svg";
case RimSummaryAddressCollection::CollectionContentType::REGION_2_REGION:
return ":/summary/components/images/region-region.svg";
case RimSummaryAddressCollection::CollectionContentType::WELL_COMPLETION:
return ":/summary/components/images/well-completion.svg";
case RimSummaryAddressCollection::CollectionContentType::WELL_CONNECTION:
return ":/summary/components/images/block.svg";
case RimSummaryAddressCollection::CollectionContentType::WELL_LGR:
return ":/summary/components/images/well.svg";
case RimSummaryAddressCollection::CollectionContentType::WELL_COMPLETION_LGR:
return ":/summary/components/images/well-completion.svg";
case RimSummaryAddressCollection::CollectionContentType::WELL_CONNECTION_LGR:
return ":/summary/components/images/block.svg";
case RimSummaryAddressCollection::CollectionContentType::WELL_SEGMENT:
return ":/summary/components/images/segment.svg";
case RimSummaryAddressCollection::CollectionContentType::BLOCK_LGR:

View File

@ -53,8 +53,9 @@ public:
NETWORK,
REGION_2_REGION,
WELL_COMPLETION,
WELL_CONNECTION,
WELL_LGR,
WELL_COMPLETION_LGR,
WELL_CONNECTION_LGR,
WELL_SEGMENT,
BLOCK_LGR,
CALCULATED,
@ -106,11 +107,10 @@ private:
int caseId,
int ensembleId = -1 );
void addToSubfolderTree( std::vector<QString> folders,
CollectionContentType folderType,
const RifEclipseSummaryAddress& address,
int caseId,
int ensembleId = -1 );
void addToSubfolderTree( std::vector<std::pair<QString, CollectionContentType>> folders,
const RifEclipseSummaryAddress& address,
int caseId,
int ensembleId = -1 );
QString iconResourceText() const;

View File

@ -51,8 +51,9 @@ RimSummaryCurveAutoName::RimSummaryCurveAutoName()
CAF_PDM_InitField( &m_groupName, "WellGroupName", true, "Group Name" );
CAF_PDM_InitField( &m_wellName, "WellName", true, "Well Name" );
CAF_PDM_InitField( &m_wellSegmentNumber, "WellSegmentNumber", true, "Well Segment Number" );
CAF_PDM_InitField( &m_wellCompletionNumber, "WellCompletionNumber", true, "Well Completion Number" );
CAF_PDM_InitField( &m_lgrName, "LgrName", true, "Lgr Name" );
CAF_PDM_InitField( &m_completion, "Completion", true, "I, J, K" );
CAF_PDM_InitField( &m_connection, "Completion", true, "I, J, K" );
CAF_PDM_InitField( &m_aquiferNumber, "Aquifer", true, "Aquifer Number" );
CAF_PDM_InitField( &m_caseName, "CaseName", true, "Case/Ensemble Name" );
@ -171,17 +172,18 @@ QString RimSummaryCurveAutoName::curveNameX( const RifEclipseSummaryAddress& sum
//--------------------------------------------------------------------------------------------------
void RimSummaryCurveAutoName::applySettings( const RimSummaryCurveAutoName& other )
{
m_caseName = other.m_caseName;
m_vectorName = other.m_vectorName;
m_longVectorName = other.m_longVectorName;
m_unit = other.m_unit;
m_regionNumber = other.m_regionNumber;
m_groupName = other.m_groupName;
m_wellName = other.m_wellName;
m_wellSegmentNumber = other.m_wellSegmentNumber;
m_lgrName = other.m_lgrName;
m_completion = other.m_completion;
m_aquiferNumber = other.m_aquiferNumber;
m_caseName = other.m_caseName;
m_vectorName = other.m_vectorName;
m_longVectorName = other.m_longVectorName;
m_unit = other.m_unit;
m_regionNumber = other.m_regionNumber;
m_groupName = other.m_groupName;
m_wellName = other.m_wellName;
m_wellSegmentNumber = other.m_wellSegmentNumber;
m_wellCompletionNumber = other.m_wellCompletionNumber;
m_lgrName = other.m_lgrName;
m_aquiferNumber = other.m_aquiferNumber;
m_connection = other.m_connection;
}
//--------------------------------------------------------------------------------------------------
@ -356,13 +358,13 @@ void RimSummaryCurveAutoName::appendAddressDetails( std::string&
appendWellName( text, summaryAddress, nameHelper );
}
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION:
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION:
{
appendWellName( text, summaryAddress, nameHelper );
if ( m_completion )
if ( m_connection )
{
bool skipSubString = nameHelper && nameHelper->isCompletionInTitle();
bool skipSubString = nameHelper && nameHelper->isConnectionInTitle();
if ( !skipSubString )
{
if ( !text.empty() ) text += ":";
@ -378,14 +380,14 @@ void RimSummaryCurveAutoName::appendAddressDetails( std::string&
appendWellName( text, summaryAddress, nameHelper );
}
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION_LGR:
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION_LGR:
{
appendLgrName( text, summaryAddress );
appendWellName( text, summaryAddress, nameHelper );
if ( m_completion )
if ( m_connection )
{
bool skipSubString = nameHelper && nameHelper->isCompletionInTitle();
bool skipSubString = nameHelper && nameHelper->isConnectionInTitle();
if ( !skipSubString )
{
if ( !text.empty() ) text += ":";
@ -395,6 +397,21 @@ void RimSummaryCurveAutoName::appendAddressDetails( std::string&
}
}
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION:
{
appendWellName( text, summaryAddress, nameHelper );
if ( m_wellCompletionNumber )
{
bool skipSubString = nameHelper && nameHelper->isWellCompletionInTitle();
if ( !skipSubString )
{
if ( !text.empty() ) text += ":";
text += std::to_string( summaryAddress.wellCompletionNumber() );
}
}
}
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_SEGMENT:
{
appendWellName( text, summaryAddress, nameHelper );
@ -412,7 +429,7 @@ void RimSummaryCurveAutoName::appendAddressDetails( std::string&
break;
case RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_BLOCK:
{
if ( m_completion )
if ( m_connection )
{
bool skipSubString = nameHelper && nameHelper->isBlockInTitle();
if ( !skipSubString )
@ -428,7 +445,7 @@ void RimSummaryCurveAutoName::appendAddressDetails( std::string&
{
appendLgrName( text, summaryAddress );
if ( m_completion )
if ( m_connection )
{
bool skipSubString = nameHelper && nameHelper->isBlockInTitle();
if ( !skipSubString )
@ -496,8 +513,9 @@ void RimSummaryCurveAutoName::defineUiOrdering( QString uiConfigName, caf::PdmUi
advanced.setCollapsedByDefault();
advanced.add( &m_regionNumber );
advanced.add( &m_lgrName );
advanced.add( &m_completion );
advanced.add( &m_connection );
advanced.add( &m_wellSegmentNumber );
advanced.add( &m_wellCompletionNumber );
advanced.add( &m_aquiferNumber );
advanced.add( &m_unit );

View File

@ -68,8 +68,9 @@ private:
caf::PdmField<bool> m_groupName;
caf::PdmField<bool> m_wellName;
caf::PdmField<bool> m_wellSegmentNumber;
caf::PdmField<bool> m_wellCompletionNumber;
caf::PdmField<bool> m_lgrName;
caf::PdmField<bool> m_completion;
caf::PdmField<bool> m_connection;
caf::PdmField<bool> m_aquiferNumber;
caf::PdmField<bool> m_caseName;

View File

@ -27,16 +27,20 @@ namespace caf
template <>
void AppEnum<RimSummaryDataSourceStepping::SourceSteppingDimension>::setUp()
{
addItem( RimSummaryDataSourceStepping::SourceSteppingDimension::ENSEMBLE, "ENSEMBLE", "Ensemble" );
addItem( RimSummaryDataSourceStepping::SourceSteppingDimension::SUMMARY_CASE, "SUMMARY_CASE", "Summary Case" );
addItem( RimSummaryDataSourceStepping::SourceSteppingDimension::VECTOR, "VECTOR", "Vector" );
addItem( RimSummaryDataSourceStepping::SourceSteppingDimension::WELL, "WELL", RiaDefines::summaryWell() );
addItem( RimSummaryDataSourceStepping::SourceSteppingDimension::GROUP, "GROUP", RiaDefines::summaryWellGroup() );
addItem( RimSummaryDataSourceStepping::SourceSteppingDimension::NETWORK, "NETWORK", RiaDefines::summaryNetwork() );
addItem( RimSummaryDataSourceStepping::SourceSteppingDimension::REGION, "REGION", RiaDefines::summaryRegion() );
addItem( RimSummaryDataSourceStepping::SourceSteppingDimension::BLOCK, "BLOCK", RiaDefines::summaryBlock() );
addItem( RimSummaryDataSourceStepping::SourceSteppingDimension::AQUIFER, "AQUIFER", RiaDefines::summaryAquifer() );
addItem( RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_SEGMENT, "WELL_SEGMENT", RiaDefines::summaryWellSegment() );
setDefault( RimSummaryDataSourceStepping::SourceSteppingDimension::VECTOR );
using ssd = RimSummaryDataSourceStepping::SourceSteppingDimension;
addItem( ssd::ENSEMBLE, "ENSEMBLE", "Ensemble" );
addItem( ssd::SUMMARY_CASE, "SUMMARY_CASE", "Summary Case" );
addItem( ssd::VECTOR, "VECTOR", "Vector" );
addItem( ssd::WELL, "WELL", RiaDefines::summaryWell() );
addItem( ssd::GROUP, "GROUP", RiaDefines::summaryWellGroup() );
addItem( ssd::NETWORK, "NETWORK", RiaDefines::summaryNetwork() );
addItem( ssd::REGION, "REGION", RiaDefines::summaryRegion() );
addItem( ssd::WELL_COMPLETION_NUMBER, "WELL_COMPLETION", RiaDefines::summaryWellCompletion() );
addItem( ssd::WELL_CONNECTION, "WELL_CONNECTION", RiaDefines::summaryWellConnection() );
addItem( ssd::BLOCK, "BLOCK", RiaDefines::summaryBlock() );
addItem( ssd::AQUIFER, "AQUIFER", RiaDefines::summaryAquifer() );
addItem( ssd::WELL_SEGMENT, "WELL_SEGMENT", RiaDefines::summaryWellSegment() );
setDefault( ssd::VECTOR );
}
} // namespace caf

View File

@ -35,9 +35,11 @@ public:
NETWORK,
REGION,
VECTOR,
WELL_COMPLETION_NUMBER,
WELL_CONNECTION,
BLOCK,
AQUIFER,
WELL_SEGMENT
WELL_SEGMENT,
};
public:

View File

@ -817,7 +817,15 @@ void RimSummaryMultiPlot::setDefaultRangeAggregationSteppingDimension()
}
auto stepDimension = RimSummaryDataSourceStepping::SourceSteppingDimension::VECTOR;
if ( analyzer.wellNames().size() == 1 )
if ( analyzer.regionNumbers().size() == 1 )
{
stepDimension = RimSummaryDataSourceStepping::SourceSteppingDimension::REGION;
}
else if ( analyzer.groupNames().size() == 1 )
{
stepDimension = RimSummaryDataSourceStepping::SourceSteppingDimension::GROUP;
}
else if ( analyzer.wellNames().size() == 1 )
{
auto wellName = *( analyzer.wellNames().begin() );
@ -825,23 +833,23 @@ void RimSummaryMultiPlot::setDefaultRangeAggregationSteppingDimension()
{
stepDimension = RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_SEGMENT;
}
else if ( analyzer.wellCompletionNumbers( wellName ).size() == 1 )
{
stepDimension = RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_COMPLETION_NUMBER;
}
else if ( analyzer.wellConnections( wellName ).size() == 1 )
{
stepDimension = RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_CONNECTION;
}
else
{
stepDimension = RimSummaryDataSourceStepping::SourceSteppingDimension::WELL;
}
}
else if ( analyzer.groupNames().size() == 1 )
{
stepDimension = RimSummaryDataSourceStepping::SourceSteppingDimension::GROUP;
}
else if ( analyzer.networkNames().size() == 1 )
{
stepDimension = RimSummaryDataSourceStepping::SourceSteppingDimension::NETWORK;
}
else if ( analyzer.regionNumbers().size() == 1 )
{
stepDimension = RimSummaryDataSourceStepping::SourceSteppingDimension::REGION;
}
else if ( analyzer.aquifers().size() == 1 )
{
stepDimension = RimSummaryDataSourceStepping::SourceSteppingDimension::AQUIFER;

View File

@ -78,11 +78,18 @@ QString RimSummaryNameHelper::aggregatedPlotTitle( const RimSummaryNameHelper& o
title += "Segment : " + QString::fromStdString( segment );
}
auto completion = titleCompletion();
if ( !other.isCompletionInTitle() && !completion.empty() )
auto wellCompletion = titleWellCompletion();
if ( !other.isWellCompletionInTitle() && !wellCompletion.empty() )
{
if ( !title.isEmpty() ) title += ", ";
title += "Completion : " + QString::fromStdString( completion );
title += "Well Completion : " + QString::fromStdString( wellCompletion );
}
auto connection = titleConnection();
if ( !other.isConnectionInTitle() && !connection.empty() )
{
if ( !title.isEmpty() ) title += ", ";
title += "Connection : " + QString::fromStdString( connection );
}
auto vectorName = titleVectorName();

View File

@ -46,19 +46,21 @@ public:
virtual bool isCaseInTitle() const = 0;
virtual bool isBlockInTitle() const = 0;
virtual bool isSegmentInTitle() const = 0;
virtual bool isCompletionInTitle() const = 0;
virtual bool isConnectionInTitle() const = 0;
virtual bool isWellCompletionInTitle() const = 0;
virtual std::vector<std::string> vectorNames() const = 0;
virtual QString caseName() const = 0;
virtual std::string titleVectorName() const = 0;
virtual std::string titleWellName() const = 0;
virtual std::string titleGroupName() const = 0;
virtual std::string titleNetwork() const = 0;
virtual std::string titleRegion() const = 0;
virtual std::string titleBlock() const = 0;
virtual std::string titleSegment() const = 0;
virtual std::string titleCompletion() const = 0;
virtual std::string titleVectorName() const = 0;
virtual std::string titleWellName() const = 0;
virtual std::string titleGroupName() const = 0;
virtual std::string titleNetwork() const = 0;
virtual std::string titleRegion() const = 0;
virtual std::string titleBlock() const = 0;
virtual std::string titleSegment() const = 0;
virtual std::string titleWellCompletion() const = 0;
virtual std::string titleConnection() const = 0;
virtual size_t numberOfCases() const = 0;
};

View File

@ -184,9 +184,17 @@ bool RimSummaryPlotNameHelper::isSegmentInTitle() const
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
bool RimSummaryPlotNameHelper::isCompletionInTitle() const
bool RimSummaryPlotNameHelper::isWellCompletionInTitle() const
{
return !m_titleCompletion.empty();
return !m_titleWellCompletion.empty();
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
bool RimSummaryPlotNameHelper::isConnectionInTitle() const
{
return !m_titleConnection.empty();
}
//--------------------------------------------------------------------------------------------------
@ -264,9 +272,17 @@ std::string RimSummaryPlotNameHelper::titleSegment() const
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
std::string RimSummaryPlotNameHelper::titleCompletion() const
std::string RimSummaryPlotNameHelper::titleWellCompletion() const
{
return m_titleCompletion;
return m_titleWellCompletion;
}
//--------------------------------------------------------------------------------------------------
///
//--------------------------------------------------------------------------------------------------
std::string RimSummaryPlotNameHelper::titleConnection() const
{
return m_titleConnection;
}
//--------------------------------------------------------------------------------------------------
@ -289,7 +305,8 @@ void RimSummaryPlotNameHelper::clearTitleSubStrings()
m_titleRegion.clear();
m_titleBlock.clear();
m_titleSegment.clear();
m_titleCompletion.clear();
m_titleConnection.clear();
m_titleWellCompletion.clear();
m_titleCaseName.clear();
}
@ -325,10 +342,18 @@ void RimSummaryPlotNameHelper::extractPlotTitleSubStrings()
}
{
auto completions = m_analyzer->wellCompletions( m_titleWellName );
if ( completions.size() == 1 )
auto wellCompletionNumbers = m_analyzer->wellCompletionNumbers( m_titleWellName );
if ( wellCompletionNumbers.size() == 1 )
{
m_titleCompletion = *( completions.begin() );
m_titleWellCompletion = std::to_string( *( wellCompletionNumbers.begin() ) );
}
}
{
auto connections = m_analyzer->wellConnections( m_titleWellName );
if ( connections.size() == 1 )
{
m_titleConnection = *( connections.begin() );
}
}
}

View File

@ -59,7 +59,8 @@ public:
bool isCaseInTitle() const override;
bool isBlockInTitle() const override;
bool isSegmentInTitle() const override;
bool isCompletionInTitle() const override;
bool isConnectionInTitle() const override;
bool isWellCompletionInTitle() const override;
std::vector<std::string> vectorNames() const override;
QString caseName() const override;
@ -71,7 +72,8 @@ public:
std::string titleRegion() const override;
std::string titleBlock() const override;
std::string titleSegment() const override;
std::string titleCompletion() const override;
std::string titleConnection() const override;
std::string titleWellCompletion() const override;
size_t numberOfCases() const override;
@ -95,7 +97,8 @@ private:
std::string m_titleRegion;
std::string m_titleBlock;
std::string m_titleSegment;
std::string m_titleCompletion;
std::string m_titleConnection;
std::string m_titleWellCompletion;
QString m_titleCaseName;
};

View File

@ -79,8 +79,9 @@ RimSummaryPlotSourceStepping::RimSummaryPlotSourceStepping()
CAF_PDM_InitFieldNoDefault( &m_cellBlock, "CellBlock", "Block" );
CAF_PDM_InitFieldNoDefault( &m_wellSegment, "Segment", "Segment" );
CAF_PDM_InitFieldNoDefault( &m_completion, "Completion", "Completion" );
CAF_PDM_InitFieldNoDefault( &m_connection, "Connection", "Connection" );
CAF_PDM_InitFieldNoDefault( &m_aquifer, "Aquifer", "Aquifer" );
CAF_PDM_InitFieldNoDefault( &m_wellCompletionNumber, "WellCompletion", "Well Completion" );
CAF_PDM_InitFieldNoDefault( &m_ensemble, "Ensemble", "Ensemble" );
@ -274,11 +275,16 @@ QList<caf::PdmOptionItemInfo> RimSummaryPlotSourceStepping::calculateValueOption
secondaryIdentifier = m_wellName().toStdString();
category = SummaryCategory::SUMMARY_WELL_SEGMENT;
}
else if ( fieldNeedingOptions == &m_completion )
else if ( fieldNeedingOptions == &m_wellCompletionNumber )
{
secondaryIdentifier = m_wellName().toStdString();
category = SummaryCategory::SUMMARY_WELL_COMPLETION;
}
else if ( fieldNeedingOptions == &m_connection )
{
secondaryIdentifier = m_wellName().toStdString();
category = SummaryCategory::SUMMARY_WELL_CONNECTION;
}
else if ( fieldNeedingOptions == &m_aquifer )
{
category = SummaryCategory::SUMMARY_AQUIFER;
@ -480,14 +486,18 @@ void RimSummaryPlotSourceStepping::fieldChangedByUi( const caf::PdmFieldHandle*
{
summaryCategoryToModify = SummaryCategory::SUMMARY_WELL_SEGMENT;
}
else if ( changedField == &m_completion )
else if ( changedField == &m_connection )
{
summaryCategoryToModify = SummaryCategory::SUMMARY_WELL_COMPLETION;
summaryCategoryToModify = SummaryCategory::SUMMARY_WELL_CONNECTION;
}
else if ( changedField == &m_aquifer )
{
summaryCategoryToModify = SummaryCategory::SUMMARY_AQUIFER;
}
else if ( changedField == &m_wellCompletionNumber )
{
summaryCategoryToModify = SummaryCategory::SUMMARY_WELL_COMPLETION;
}
if ( summaryCategoryToModify != SummaryCategory::SUMMARY_INVALID )
{
@ -590,6 +600,12 @@ caf::PdmValueField* RimSummaryPlotSourceStepping::fieldToModify()
case RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_SEGMENT:
return &m_wellSegment;
case RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_COMPLETION_NUMBER:
return &m_wellCompletionNumber;
case RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_CONNECTION:
return &m_connection;
default:
break;
}
@ -840,12 +856,12 @@ std::vector<caf::PdmFieldHandle*> RimSummaryPlotSourceStepping::activeFieldsForD
fieldsCommonForAllCurves.push_back( &m_cellBlock );
}
if ( analyzer.wellCompletions( m_wellName().toStdString() ).size() == 1 )
if ( analyzer.wellConnections( m_wellName().toStdString() ).size() == 1 )
{
QString txt = QString::fromStdString( *( analyzer.wellCompletions( m_wellName().toStdString() ).begin() ) );
m_completion = txt;
QString txt = QString::fromStdString( *( analyzer.wellConnections( m_wellName().toStdString() ).begin() ) );
m_connection = txt;
fieldsCommonForAllCurves.push_back( &m_completion );
fieldsCommonForAllCurves.push_back( &m_connection );
}
if ( analyzer.aquifers().size() == 1 )
@ -855,6 +871,13 @@ std::vector<caf::PdmFieldHandle*> RimSummaryPlotSourceStepping::activeFieldsForD
fieldsCommonForAllCurves.push_back( &m_aquifer );
}
if ( analyzer.wellCompletionNumbers( m_wellName().toStdString() ).size() == 1 )
{
m_wellCompletionNumber = *( analyzer.wellCompletionNumbers( m_wellName().toStdString() ).begin() );
fieldsCommonForAllCurves.push_back( &m_wellCompletionNumber );
}
if ( !analyzer.quantityNameForTitle().empty() )
{
QString txt = QString::fromStdString( analyzer.quantityNameForTitle() );
@ -1081,6 +1104,15 @@ RifEclipseSummaryAddress RimSummaryPlotSourceStepping::stepAddress( RifEclipseSu
}
break;
case RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_COMPLETION_NUMBER:
{
auto ids = analyzer.identifierTexts( SummaryCategory::SUMMARY_WELL_COMPLETION, "" );
auto searchString = QString::number( addr.wellCompletionNumber() );
auto found = getIdIterator( ids, searchString );
if ( found != ids.end() ) addr.setWellCompletionNumber( ( *found ).toInt() );
}
break;
default:
break;
}
@ -1130,10 +1162,18 @@ void RimSummaryPlotSourceStepping::syncWithStepper( RimSummaryPlotSourceStepping
m_aquifer = other->m_aquifer();
break;
case RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_COMPLETION_NUMBER:
m_wellCompletionNumber = other->m_wellCompletionNumber();
break;
case RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_SEGMENT:
m_wellSegment = other->m_wellSegment();
break;
case RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_CONNECTION:
m_connection = other->m_connection();
break;
default:
break;
}
@ -1168,6 +1208,10 @@ void RimSummaryPlotSourceStepping::setStep( QString stepIdentifier )
m_cellBlock.setValueWithFieldChanged( stepIdentifier );
break;
case RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_CONNECTION:
m_connection.setValueWithFieldChanged( stepIdentifier );
break;
case RimSummaryDataSourceStepping::SourceSteppingDimension::AQUIFER:
case RimSummaryDataSourceStepping::SourceSteppingDimension::REGION:
case RimSummaryDataSourceStepping::SourceSteppingDimension::ENSEMBLE:
@ -1407,7 +1451,9 @@ std::vector<RimPlot*> RimSummaryPlotSourceStepping::plotsMatchingStepSettings( s
int regionToMatch = -1;
std::string vectorToMatch;
std::string blockToMatch;
int aquiferToMatch = -1;
std::string connectionToMatch;
int aquiferToMatch = -1;
int wellCompletionNumberToMatch = -1;
switch ( m_stepDimension() )
{
@ -1447,6 +1493,14 @@ std::vector<RimPlot*> RimSummaryPlotSourceStepping::plotsMatchingStepSettings( s
aquiferToMatch = m_aquifer();
break;
case RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_COMPLETION_NUMBER:
wellCompletionNumberToMatch = m_wellCompletionNumber();
break;
case RimSummaryDataSourceStepping::SourceSteppingDimension::WELL_CONNECTION:
connectionToMatch = m_connection().toStdString();
break;
default:
break;
}
@ -1505,6 +1559,14 @@ std::vector<RimPlot*> RimSummaryPlotSourceStepping::plotsMatchingStepSettings( s
{
isMatching = true;
}
else if ( wellCompletionNumberToMatch != -1 && a.wellCompletionNumber() == wellCompletionNumberToMatch )
{
isMatching = true;
}
else if ( !connectionToMatch.empty() && a.connectionAsString() == connectionToMatch )
{
isMatching = true;
}
}
}

View File

@ -121,9 +121,10 @@ private:
caf::PdmField<QString> m_cellBlock;
caf::PdmField<QString> m_wellSegment;
caf::PdmField<QString> m_completion;
caf::PdmField<QString> m_connection;
caf::PdmField<int> m_aquifer;
caf::PdmField<int> m_wellCompletionNumber;
caf::PdmField<bool> m_includeEnsembleCasesForCaseStepping;
caf::PdmField<bool> m_autoUpdateAppearance;

View File

@ -1061,7 +1061,7 @@ TEST( RifKeywordBasedRsmspecParserTest, TestAddressCreation )
RifEclipseSummaryAddress address = RifEclipseUserDataKeywordTools::makeAndFillAddress( quantityName, headerColumn );
EXPECT_TRUE( address.isValid() );
EXPECT_EQ( address.category(), RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION_LGR );
EXPECT_EQ( address.category(), RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION_LGR );
EXPECT_EQ( address.uiText(), "LCABC:lgrName:wellName:12,14,16" );
}

View File

@ -12,30 +12,30 @@ TEST( RiaSummaryAddressAnalyzer, WellCompletions )
// Well A
std::string wellNameA = "well_name_a";
{
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellCompletionAddress( "quantity_name", wellNameA, 1, 2, 3 );
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellConnectionAddress( "quantity_name", wellNameA, 1, 2, 3 );
addresses.push_back( adr );
}
{
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellCompletionAddress( "quantity_name", wellNameA, 1, 2, 3 );
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellConnectionAddress( "quantity_name", wellNameA, 1, 2, 3 );
addresses.push_back( adr );
}
{
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellCompletionAddress( "quantity_name", wellNameA, 5, 2, 3 );
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellConnectionAddress( "quantity_name", wellNameA, 5, 2, 3 );
addresses.push_back( adr );
}
// Well B
std::string wellNameB = "well_name_b";
{
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellCompletionAddress( "quantity_name", wellNameB, 5, 2, 3 );
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellConnectionAddress( "quantity_name", wellNameB, 5, 2, 3 );
addresses.push_back( adr );
}
{
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellCompletionAddress( "quantity_name", wellNameB, 5, 4, 3 );
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellConnectionAddress( "quantity_name", wellNameB, 5, 4, 3 );
addresses.push_back( adr );
}
{
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellCompletionAddress( "quantity_name", wellNameB, 5, 4, 30 );
RifEclipseSummaryAddress adr = RifEclipseSummaryAddress::wellConnectionAddress( "quantity_name", wellNameB, 5, 4, 30 );
addresses.push_back( adr );
}
@ -44,13 +44,13 @@ TEST( RiaSummaryAddressAnalyzer, WellCompletions )
EXPECT_EQ( 2u, analyzer.wellNames().size() );
auto completionsForA = analyzer.wellCompletions( wellNameA );
EXPECT_EQ( 2u, completionsForA.size() );
auto connectionsForA = analyzer.wellConnections( wellNameA );
EXPECT_EQ( 2u, connectionsForA.size() );
auto completionsForB = analyzer.wellCompletions( wellNameB );
EXPECT_EQ( 3u, completionsForB.size() );
auto connectionsForB = analyzer.wellConnections( wellNameB );
EXPECT_EQ( 3u, connectionsForB.size() );
std::string tupleToFind = "5,4,30";
EXPECT_TRUE( completionsForB.find( tupleToFind ) != completionsForB.end() );
EXPECT_TRUE( connectionsForB.find( tupleToFind ) != connectionsForB.end() );
}
//--------------------------------------------------------------------------------------------------

View File

@ -126,19 +126,33 @@ TEST( RifEclipseSummaryAddressTest, TestEclipseAddressParsing_Well )
EXPECT_FALSE( addr.isErrorResult() );
}
TEST( RifEclipseSummaryAddressTest, TestEclipseAddressParsing_WellConnection )
{
std::string addrString = "CPRL:B-1H:15,13,14";
RifEclipseSummaryAddress addr = RifEclipseSummaryAddress::fromEclipseTextAddressParseErrorTokens( addrString );
EXPECT_TRUE( addr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION, addr.category() );
EXPECT_EQ( "CPRL", addr.vectorName() );
EXPECT_EQ( "B-1H", addr.wellName() );
EXPECT_EQ( 15, addr.cellI() );
EXPECT_EQ( 13, addr.cellJ() );
EXPECT_EQ( 14, addr.cellK() );
EXPECT_FALSE( addr.isErrorResult() );
}
TEST( RifEclipseSummaryAddressTest, TestEclipseAddressParsing_WellCompletion )
{
std::string addrString = "COFRL:B-1H:15,13,14";
std::string addrString = "WGLRL:B-1H:15";
RifEclipseSummaryAddress addr = RifEclipseSummaryAddress::fromEclipseTextAddressParseErrorTokens( addrString );
EXPECT_TRUE( addr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION, addr.category() );
EXPECT_EQ( "COFRL", addr.vectorName() );
EXPECT_EQ( "WGLRL", addr.vectorName() );
EXPECT_EQ( "B-1H", addr.wellName() );
EXPECT_EQ( 15, addr.cellI() );
EXPECT_EQ( 13, addr.cellJ() );
EXPECT_EQ( 14, addr.cellK() );
EXPECT_EQ( 15, addr.wellCompletionNumber() );
EXPECT_FALSE( addr.isErrorResult() );
}
@ -163,7 +177,7 @@ TEST( RifEclipseSummaryAddressTest, TestEclipseAddressParsing_WellCompletionLgr
RifEclipseSummaryAddress addr = RifEclipseSummaryAddress::fromEclipseTextAddressParseErrorTokens( addrString );
EXPECT_TRUE( addr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION_LGR, addr.category() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION_LGR, addr.category() );
EXPECT_EQ( "LCGAS", addr.vectorName() );
EXPECT_EQ( "LGR1", addr.lgrName() );
EXPECT_EQ( "B-1H", addr.wellName() );
@ -250,7 +264,7 @@ TEST( RifEclipseSummaryAddressTest, TestEclipseAddressParsing_ErrorResult2 )
RifEclipseSummaryAddress addr = RifEclipseSummaryAddress::fromEclipseTextAddressParseErrorTokens( addrString );
EXPECT_TRUE( addr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION_LGR, addr.category() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION_LGR, addr.category() );
EXPECT_EQ( "LCGAS", addr.vectorName() );
EXPECT_EQ( "LGR1", addr.lgrName() );
EXPECT_EQ( "B-1H", addr.wellName() );
@ -274,7 +288,7 @@ TEST( RifEclipseSummaryAddressTest, TestEclipseAddressParsing_ErrorResult3 )
TEST( RifEclipseSummaryAddressTest, TestEclipseAddressIjkParsing )
{
RifEclipseSummaryAddressDefines::SummaryCategory cat = RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION;
RifEclipseSummaryAddressDefines::SummaryCategory cat = RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION;
std::map<RifEclipseSummaryAddressDefines::SummaryIdentifierType, std::string> identifiers( {
{ RifEclipseSummaryAddressDefines::SummaryIdentifierType::INPUT_WELL_NAME, "1-BH" },
{ RifEclipseSummaryAddressDefines::SummaryIdentifierType::INPUT_CELL_IJK, "6, 7, 8" },
@ -284,7 +298,7 @@ TEST( RifEclipseSummaryAddressTest, TestEclipseAddressIjkParsing )
RifEclipseSummaryAddress addr( cat, identifiers );
EXPECT_TRUE( addr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION, addr.category() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION, addr.category() );
EXPECT_EQ( "WOPR", addr.vectorName() );
EXPECT_EQ( "1-BH", addr.wellName() );
EXPECT_EQ( 6, addr.cellI() );
@ -392,3 +406,192 @@ TEST( RifEclipseSummaryAddressTest, LogicalOperators )
EXPECT_TRUE( addresses.at( 8 ) == block_c );
EXPECT_TRUE( addresses.at( 9 ) == block_d );
}
TEST( RifEclipseSummaryAddressTest, ConversionFromTextToAddress )
{
// Aquifer
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "AAQR:456" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_AQUIFER, adr.category() );
EXPECT_EQ( "AAQR", adr.vectorName() );
EXPECT_EQ( 456, adr.aquiferNumber() );
}
// Unknown aquifer
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "AAQCEE:2" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_AQUIFER, adr.category() );
EXPECT_EQ( "AAQCEE", adr.vectorName() );
EXPECT_EQ( 2, adr.aquiferNumber() );
}
// Block
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "BPR:123,122,121" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_BLOCK, adr.category() );
EXPECT_EQ( "BPR", adr.vectorName() );
EXPECT_EQ( 123, adr.cellI() );
EXPECT_EQ( 122, adr.cellJ() );
EXPECT_EQ( 121, adr.cellK() );
}
// Unknown block
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "BPGTEST:1,2,3" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_BLOCK, adr.category() );
EXPECT_EQ( "BPGTEST", adr.vectorName() );
EXPECT_EQ( 1, adr.cellI() );
EXPECT_EQ( 2, adr.cellJ() );
EXPECT_EQ( 3, adr.cellK() );
}
// Well completion
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "WGLRL:B-1H:15" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION, adr.category() );
EXPECT_EQ( "WGLRL", adr.vectorName() );
EXPECT_EQ( "B-1H", adr.wellName() );
EXPECT_EQ( 15, adr.wellCompletionNumber() );
}
// Unknown well completion
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "WGLRTESAT:B-1H:15" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION, adr.category() );
EXPECT_EQ( "WGLRTESAT", adr.vectorName() );
EXPECT_EQ( "B-1H", adr.wellName() );
EXPECT_EQ( 15, adr.wellCompletionNumber() );
}
// Well connection
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "CPRL:B-1H:15,13,14" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION, adr.category() );
EXPECT_EQ( "CPRL", adr.vectorName() );
EXPECT_EQ( "B-1H", adr.wellName() );
EXPECT_EQ( 15, adr.cellI() );
EXPECT_EQ( 13, adr.cellJ() );
EXPECT_EQ( 14, adr.cellK() );
}
// Unknown well connection
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "CAPIRSS:B-1H:15,13,22" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION, adr.category() );
EXPECT_EQ( "CAPIRSS", adr.vectorName() );
EXPECT_EQ( "B-1H", adr.wellName() );
EXPECT_EQ( 15, adr.cellI() );
EXPECT_EQ( 13, adr.cellJ() );
EXPECT_EQ( 22, adr.cellK() );
}
// Field
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "FOPT" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_FIELD, adr.category() );
EXPECT_EQ( "FOPT", adr.vectorName() );
}
// Unknown field
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "FOPCEE" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_FIELD, adr.category() );
EXPECT_EQ( "FOPCEE", adr.vectorName() );
}
// Group
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "GOPR:WELLS1" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_GROUP, adr.category() );
EXPECT_EQ( "GOPR", adr.vectorName() );
EXPECT_EQ( "WELLS1", adr.groupName() );
}
// Unknown group
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "GOPRTEST:WELLS1" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_GROUP, adr.category() );
EXPECT_EQ( "GOPRTEST", adr.vectorName() );
EXPECT_EQ( "WELLS1", adr.groupName() );
}
// Region
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "RPR:7081" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_REGION, adr.category() );
EXPECT_EQ( "RPR", adr.vectorName() );
EXPECT_EQ( 7081, adr.regionNumber() );
}
// Unknown region
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "RPRTEST:7081" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_REGION, adr.category() );
EXPECT_EQ( "RPRTEST", adr.vectorName() );
EXPECT_EQ( 7081, adr.regionNumber() );
}
// Region to region
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "RGFT:7081-8001" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_REGION_2_REGION, adr.category() );
EXPECT_EQ( "RGFT", adr.vectorName() );
EXPECT_EQ( 7081, adr.regionNumber() );
EXPECT_EQ( 8001, adr.regionNumber2() );
}
// Unknown region to region is skipped, no general rule to identify region to region
// Segment
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "SOFR:B-5H:32" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_SEGMENT, adr.category() );
EXPECT_EQ( "SOFR", adr.vectorName() );
EXPECT_EQ( "B-5H", adr.wellName() );
EXPECT_EQ( 32, adr.wellSegmentNumber() );
}
// Unknown segment
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "SOFRTEST:B-5H:32" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_SEGMENT, adr.category() );
EXPECT_EQ( "SOFRTEST", adr.vectorName() );
EXPECT_EQ( "B-5H", adr.wellName() );
EXPECT_EQ( 32, adr.wellSegmentNumber() );
}
// Well
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "WOPR:B-2H" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL, adr.category() );
EXPECT_EQ( "WOPR", adr.vectorName() );
EXPECT_EQ( "B-2H", adr.wellName() );
}
// Unknown well
{
auto adr = RifEclipseSummaryAddress::fromEclipseTextAddress( "WOPRTEST:B-2H" );
EXPECT_TRUE( adr.isValid() );
EXPECT_EQ( RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL, adr.category() );
EXPECT_EQ( "WOPRTEST", adr.vectorName() );
EXPECT_EQ( "B-2H", adr.wellName() );
}
}

View File

@ -18,7 +18,9 @@
#include "RiuSummaryQuantityNameInfoProvider.h"
#include "RiaStdStringTools.h"
#include "RifEclipseSummaryAddress.h"
#include "RifOpmCommonSummary.h"
#include "cafAppEnum.h"
@ -76,6 +78,18 @@ RifEclipseSummaryAddressDefines::SummaryCategory RiuSummaryQuantityNameInfoProvi
if ( ( vectorName.size() < 3 || vectorName.size() > 8 ) && !vectorName.ends_with( RifEclipseSummaryAddressDefines::differenceIdentifier() ) )
return RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_INVALID;
auto tokens = RiaStdStringTools::splitString( vectorName, ':' );
if ( tokens.size() == 3 && tokens[0].starts_with( "W" ) )
{
return RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION;
}
if ( auto category = RifOpmCommonSummaryTools::categoryFromKeyword( vectorName );
category != RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_INVALID )
{
return category;
}
// Try to match the base vector name with more heuristics
auto strippedQuantityName = RifEclipseSummaryAddress::baseVectorName( vectorName );
@ -113,7 +127,7 @@ RifEclipseSummaryAddressDefines::SummaryCategory RiuSummaryQuantityNameInfoProvi
std::string firstTwoLetters = strippedQuantityName.substr( 0, 2 );
if ( firstTwoLetters == "LB" ) return RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_BLOCK_LGR;
if ( firstTwoLetters == "LC" ) return RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_COMPLETION_LGR;
if ( firstTwoLetters == "LC" ) return RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_CONNECTION_LGR;
if ( firstTwoLetters == "LW" ) return RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_WELL_LGR;
return RifEclipseSummaryAddressDefines::SummaryCategory::SUMMARY_INVALID;
@ -223,5 +237,15 @@ std::string RiuSummaryQuantityNameInfoProvider::stringFromEnum( RifEclipseSummar
//--------------------------------------------------------------------------------------------------
RifEclipseSummaryAddressDefines::SummaryCategory RiuSummaryQuantityNameInfoProvider::enumFromString( const std::string& category )
{
return caf::AppEnum<RifEclipseSummaryAddressDefines::SummaryCategory>::fromText( QString::fromStdString( category ) );
auto qstring = QString::fromStdString( category );
auto valid = caf::AppEnum<RifEclipseSummaryAddressDefines::SummaryCategory>::isValid( qstring );
if ( !valid )
{
// The category strings in keywords*.json must be mapped to the enum values in the enum definition
// Ensure that the strings in the json file are correct in /ApplicationLibCode/Application/Resources/keyword-description
throw std::runtime_error( "Invalid category string: " + category );
}
return caf::AppEnum<RifEclipseSummaryAddressDefines::SummaryCategory>::fromText( qstring );
}

View File

@ -126,12 +126,12 @@ RiuSummaryVectorSelectionUi::RiuSummaryVectorSelectionUi()
{ new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_WELL_NAME ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_VECTOR_NAME ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_ID ) } },
{ SummaryCategory::SUMMARY_WELL_COMPLETION,
{ SummaryCategory::SUMMARY_WELL_CONNECTION,
{ new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_WELL_NAME ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_CELL_IJK ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_VECTOR_NAME ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_ID ) } },
{ SummaryCategory::SUMMARY_WELL_COMPLETION_LGR,
{ SummaryCategory::SUMMARY_WELL_CONNECTION_LGR,
{ new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_LGR_NAME ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_WELL_NAME ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_CELL_IJK ),
@ -147,6 +147,11 @@ RiuSummaryVectorSelectionUi::RiuSummaryVectorSelectionUi()
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_SEGMENT_NUMBER ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_VECTOR_NAME ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_ID ) } },
{ SummaryCategory::SUMMARY_WELL_COMPLETION,
{ new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_WELL_NAME ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_WELL_COMPLETION_NUMBER ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_VECTOR_NAME ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_ID ) } },
{ SummaryCategory::SUMMARY_BLOCK,
{ new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_CELL_IJK ),
new SummaryIdentifierAndField( SummaryIdentifierType::INPUT_VECTOR_NAME ),
@ -211,31 +216,31 @@ RiuSummaryVectorSelectionUi::RiuSummaryVectorSelectionUi()
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL][1]->pdmField(), "WellVectors", "Well Vectors" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL][2]->pdmField(), "WellCalculationIds", "Calculation Ids" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][0]->pdmField(),
"WellCompletionWellName",
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION][0]->pdmField(),
"WellConnectionWellName",
"Wells" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][1]->pdmField(), "WellCompletionIjk", "Cell IJK" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][2]->pdmField(),
"WellCompletionVectors",
"Well Completion Vectors" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][3]->pdmField(),
"WellCompletionCalculationIds",
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION][1]->pdmField(), "WellConnectionIjk", "Cell IJK" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION][2]->pdmField(),
"WellConnectionVectors",
"Well Connection Vectors" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION][3]->pdmField(),
"WellConnectionCalculationIds",
"Calculation Ids" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION_LGR][0]->pdmField(),
"WellCompletionLgrLgrName",
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION_LGR][0]->pdmField(),
"WellConnectionLgrLgrName",
"LGR Names" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION_LGR][1]->pdmField(),
"WellCompletionLgrWellName",
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION_LGR][1]->pdmField(),
"WellConnectionLgrWellName",
"Wells" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION_LGR][2]->pdmField(),
"WellCompletionLgrIjk",
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION_LGR][2]->pdmField(),
"WellConnectionLgrIjk",
"Cell IJK" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION_LGR][3]->pdmField(),
"WellCompletionLgrVectors",
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION_LGR][3]->pdmField(),
"WellConnectionLgrVectors",
"Well Completion Vectors" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION_LGR][4]->pdmField(),
"WellCompletionLgrCalculationIds",
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION_LGR][4]->pdmField(),
"WellConnectionLgrCalculationIds",
"Calculation Ids" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_LGR][0]->pdmField(), "WellLgrLgrName", "LGR Names" );
@ -252,6 +257,19 @@ RiuSummaryVectorSelectionUi::RiuSummaryVectorSelectionUi()
"WellSegmentCalculationIds",
"Calculation Ids" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][0]->pdmField(),
"WellCompletionWellName",
"Wells" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][1]->pdmField(),
"WellCompletionNumber",
"Completion Numbers" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][2]->pdmField(),
"WellCompletionVectors",
"Vectors" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][3]->pdmField(),
"WellCompletionCalculationIds",
"Calculation Ids" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_BLOCK][0]->pdmField(), "BlockIjk", "Cell IJK" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_BLOCK][1]->pdmField(), "BlockVectors", "Block Vectors" );
CAF_PDM_InitFieldNoDefault( m_identifierFieldsMap[SummaryCategory::SUMMARY_BLOCK][2]->pdmField(), "BlockCalculationIds", "Calculation Ids" );
@ -900,26 +918,26 @@ void RiuSummaryVectorSelectionUi::defineUiOrdering( QString uiConfigName, caf::P
summaryiesField = m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL][1]->pdmField();
}
else if ( sumCategory == SummaryCategory::SUMMARY_WELL_COMPLETION )
else if ( sumCategory == SummaryCategory::SUMMARY_WELL_CONNECTION )
{
{
caf::PdmUiGroup* myGroup = uiOrdering.addNewGroup( RiaDefines::summaryCompletion() + "s" );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][0]->pdmField() );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][1]->pdmField() );
caf::PdmUiGroup* myGroup = uiOrdering.addNewGroup( RiaDefines::summaryWellConnection() + "s" );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION][0]->pdmField() );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION][1]->pdmField() );
}
summaryiesField = m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][2]->pdmField();
summaryiesField = m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION][2]->pdmField();
}
else if ( sumCategory == SummaryCategory::SUMMARY_WELL_COMPLETION_LGR )
else if ( sumCategory == SummaryCategory::SUMMARY_WELL_CONNECTION_LGR )
{
{
caf::PdmUiGroup* myGroup = uiOrdering.addNewGroup( RiaDefines::summaryLgrCompletion() + "s" );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION_LGR][0]->pdmField() );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION_LGR][1]->pdmField() );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION_LGR][2]->pdmField() );
caf::PdmUiGroup* myGroup = uiOrdering.addNewGroup( RiaDefines::summaryLgrConnection() + "s" );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION_LGR][0]->pdmField() );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION_LGR][1]->pdmField() );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION_LGR][2]->pdmField() );
}
summaryiesField = m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION_LGR][3]->pdmField();
summaryiesField = m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_CONNECTION_LGR][3]->pdmField();
}
else if ( sumCategory == SummaryCategory::SUMMARY_WELL_LGR )
{
@ -941,6 +959,16 @@ void RiuSummaryVectorSelectionUi::defineUiOrdering( QString uiConfigName, caf::P
summaryiesField = m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_SEGMENT][2]->pdmField();
}
else if ( sumCategory == SummaryCategory::SUMMARY_WELL_COMPLETION )
{
{
caf::PdmUiGroup* myGroup = uiOrdering.addNewGroup( RiaDefines::summaryWellCompletion() + "s" );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][0]->pdmField() );
myGroup->add( m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][1]->pdmField() );
}
summaryiesField = m_identifierFieldsMap[SummaryCategory::SUMMARY_WELL_COMPLETION][2]->pdmField();
}
else if ( sumCategory == SummaryCategory::SUMMARY_BLOCK )
{
{
@ -1373,13 +1401,14 @@ void RiuSummaryVectorSelectionUi::appendOptionItemsForCategories( QList<caf::Pdm
sortedCategoriesForUi.push_back( SummaryCategory::SUMMARY_GROUP );
sortedCategoriesForUi.push_back( SummaryCategory::SUMMARY_WELL );
sortedCategoriesForUi.push_back( SummaryCategory::SUMMARY_WELL_COMPLETION );
sortedCategoriesForUi.push_back( SummaryCategory::SUMMARY_WELL_CONNECTION );
sortedCategoriesForUi.push_back( SummaryCategory::SUMMARY_BLOCK );
if ( !m_hideCalculationIncompatibleCategories )
{
sortedCategoriesForUi.push_back( SummaryCategory::SUMMARY_WELL_SEGMENT );
sortedCategoriesForUi.push_back( SummaryCategory::SUMMARY_WELL_LGR );
sortedCategoriesForUi.push_back( SummaryCategory::SUMMARY_WELL_COMPLETION_LGR );
sortedCategoriesForUi.push_back( SummaryCategory::SUMMARY_WELL_CONNECTION_LGR );
sortedCategoriesForUi.push_back( SummaryCategory::SUMMARY_BLOCK_LGR );
}
@ -1476,6 +1505,7 @@ void RiuSummaryVectorSelectionUi::appendOptionItemsForSubCategoriesAndVectors( Q
{
case SummaryIdentifierType::INPUT_REGION_NUMBER:
case SummaryIdentifierType::INPUT_SEGMENT_NUMBER:
case SummaryIdentifierType::INPUT_WELL_COMPLETION_NUMBER:
case SummaryIdentifierType::INPUT_AQUIFER_NUMBER:
{
std::set<int> values;