Exemplo n.º 1
0
"""The _qcforward module contains the base class"""

import sys
from os.path import join

import yaml
import pandas as pd

from fmu.tools._common import _QCCommon
from fmu.tools.qcdata import QCData

QCC = _QCCommon()


class QCForward(object):
    """
    The QCforward base class which has a set of QC functions that can be ran from
    either RMS python, or on disk. The input `data` will be
    somewhat different for the two run environents.

    It should be easy to add new functions to this class. The idea is to reuse
    as much as possible, and principles are:

    * For the client (user), the calling scripts shall be lean

    * All methods shall have a rich documention with examples, i.e. it shall
      be possible for users with less skills in scripting to copy/paste and then modify
      to their needs.

    """
    def __init__(self):
Exemplo n.º 2
0
"""
This private module in qcforward is used to parse data on a general level.

The resulting data will be stored as class instance attributes, e.g. self._grid

"""
from os.path import join
from glob import glob
import re

import xtgeo
from fmu.tools._common import _QCCommon

CMN = _QCCommon()


class QCData(object):
    """
    This is a class which parse/reads and stores some common data
    like 3D grids, maps etc.

    It shall be semi-agnostic to where data comes from, i.e. accept both files
    and RMS input.

    By having it as a class one can store different datasets and compare them later
    if needed. E.g. if one need to compare two grid models, they will be members
    of two different instances of the QCData()
    """
    def __init__(self):
        self._reuse = []
        self._xtgdata = {}  # All XTGeo data, to be reused