Skip to content

Commit

Permalink
Rename namespace ecl to resdata/rd
Browse files Browse the repository at this point in the history
  • Loading branch information
eivindjahren committed Oct 25, 2023
1 parent 8d6ffea commit 22614a9
Show file tree
Hide file tree
Showing 494 changed files with 17,346 additions and 17,347 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/testing.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
export DYLD_LIBRARY_PATH=$PWD/lib
ctest --output-on-failure
env:
ECL_SKIP_SIGNAL: absolutely
RD_SKIP_SIGNAL: absolutely
ERT_SHOW_BACKTRACE: yes please!


Expand Down Expand Up @@ -100,7 +100,7 @@ jobs:
cp -R {..,$PWD}/python/tests
# Env vars
export ECL_SKIP_SIGNAL=1
export RD_SKIP_SIGNAL=1
export ERT_SHOW_BACKTRACE=1
# Run tests
Expand Down
5 changes: 2 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ python/lib64
/temp-build
/libert_util/tests/data/latex_OK.pdf
/test-data/Equinor
/python/python/ert/ecl/ecl_local.py
/GPATH
/GRTAGS
/GTAGS
Expand All @@ -28,11 +27,11 @@ __resdata_info.py

/venv/
/_skbuild/
/python/ecl/version.py
/python/resdata/version.py
.*
*.egg-info/

/dist
/dist-*

CMakeSettings.json
CMakeSettings.json
34 changes: 17 additions & 17 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -79,25 +79,25 @@ conan_cmake_run(

# -----------------------------------------------------------------

set(ECL_VERSION_MAJOR 0)
set(ECL_VERSION_MINOR 0)
set(ECL_VERSION_MICRO "not-available")
set(RD_VERSION_MAJOR 0)
set(RD_VERSION_MINOR 0)
set(RD_VERSION_MICRO "not-available")

# If the micro version is not integer, that should be interpreted as a
# development version leading towards version MAJOR.MINOR.0

execute_process(COMMAND date "+%Y-%m-%d %H:%M:%S"
OUTPUT_VARIABLE ECL_BUILD_TIME)
string(STRIP "${ECL_BUILD_TIME}" ECL_BUILD_TIME)
OUTPUT_VARIABLE RD_BUILD_TIME)
string(STRIP "${RD_BUILD_TIME}" RD_BUILD_TIME)

if(ECL_VERSION)
if(RD_VERSION)
# Have we been provided with an explicitly-set version?
string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\1" ECL_VERSION_MAJOR
"${ECL_VERSION}")
string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\2" ECL_VERSION_MINOR
"${ECL_VERSION}")
string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\3" ECL_VERSION_MICRO
"${ECL_VERSION}")
string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\1" RD_VERSION_MAJOR
"${RD_VERSION}")
string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\2" RD_VERSION_MINOR
"${RD_VERSION}")
string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\3" RD_VERSION_MICRO
"${RD_VERSION}")
else()
# Otherwise try to discover it via git
find_package(Git)
Expand Down Expand Up @@ -132,11 +132,11 @@ else()
OUTPUT_VARIABLE GIT_TAG
OUTPUT_STRIP_TRAILING_WHITESPACE)

string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\1" ECL_VERSION_MAJOR
string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\1" RD_VERSION_MAJOR
"${GIT_TAG}")
string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\2" ECL_VERSION_MINOR
string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\2" RD_VERSION_MINOR
"${GIT_TAG}")
string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\3" ECL_VERSION_MICRO
string(REGEX REPLACE "^([^.]+)\\.([^.]+)\\.(.+)$" "\\3" RD_VERSION_MICRO
"${GIT_TAG}")
else()
set(GIT_COMMIT "unknown (git not found!)")
Expand All @@ -148,14 +148,14 @@ endif()

message(
STATUS
"resdata version: ${ECL_VERSION_MAJOR}.${ECL_VERSION_MINOR}.${ECL_VERSION_MICRO}"
"resdata version: ${RD_VERSION_MAJOR}.${RD_VERSION_MINOR}.${RD_VERSION_MICRO}"
)

# -----------------------------------------------------------------

option(BUILD_TESTS "Should the tests be built" OFF)
option(BUILD_APPLICATIONS "Should we build small utility applications" OFF)
option(BUILD_ECL_SUMMARY "Build the commandline application ecl_summary" OFF)
option(BUILD_RD_SUMMARY "Build the commandline application rd_summary" OFF)
option(ENABLE_PYTHON "Build and install the Python wrappers" OFF)
option(BUILD_SHARED_LIBS "Build shared libraries" ON)
option(ERT_USE_OPENMP "Use OpenMP" OFF)
Expand Down
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ compiler such as GNU GCC, the CMake build system and, optionally, zlib.

```bash
$ git clone https://github.com/Equinor/ecl
$ mkdir ecl/build
$ cd ecl/build
$ mkdir resdata/build
$ cd resdata/build
$ cmake ..
$ make
$ make install
Expand All @@ -70,8 +70,8 @@ compiler, CMake and, optionally, zlib.

```bash
$ git clone https://github.com/Equinor/ecl
$ mkdir ecl/build
$ cd ecl/build
$ mkdir resdata/build
$ cd resdata/build
$ pip install -r ../requirements.txt
$ cmake .. -DENABLE_PYTHON=ON
$ make
Expand All @@ -92,10 +92,10 @@ $ export LD_LIBRARY_PATH=/path/to/install/lib64:$LD_LIBRARY_PATH

Then you can fire up your Python interpreter and try it out:
```python
>>> from ecl.summary import EclSum
>>> from ecl.summary import RdSum
>>> import sys

>>> summary = EclSum(sys.argv[1])
>>> summary = RdSum(sys.argv[1])
>>> fopt = summary.numpy_vector("FOPT")
```

Expand Down
34 changes: 17 additions & 17 deletions applications/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@ function(target_link_resdata target)
endfunction()

if(BUILD_APPLICATIONS)
add_executable(sum_write ecl/sum_write.cpp)
add_executable(make_grid ecl/make_grid.c)
add_executable(grdecl_grid ecl/grdecl_grid.c)
add_executable(summary ecl/view_summary.cpp)
add_executable(kw_extract ecl/kw_extract.cpp)
add_executable(sum_write resdata/sum_write.cpp)
add_executable(make_grid resdata/make_grid.c)
add_executable(grdecl_grid resdata/grdecl_grid.c)
add_executable(summary resdata/view_summary.cpp)
add_executable(kw_extract resdata/kw_extract.cpp)
target_link_resdata(sum_write)
target_link_resdata(make_grid)
target_link_resdata(grdecl_grid)
Expand All @@ -23,14 +23,14 @@ if(BUILD_APPLICATIONS)

foreach(
app
ecl_pack
ecl_unpack
rd_pack
rd_unpack
grid_info
grid_dump
grid_dump_ascii
select_test
load_test)
add_executable(${app} ecl/${app}.c)
add_executable(${app} resdata/${app}.c)
target_link_resdata(${app})
list(APPEND apps ${app})
if(ERT_LINUX)
Expand All @@ -41,7 +41,7 @@ if(BUILD_APPLICATIONS)

if(ERT_LINUX)
foreach(app convert grdecl_test kw_list)
add_executable(${app} ecl/${app}.c)
add_executable(${app} resdata/${app}.c)
target_link_resdata(${app})
# The .x extension creates problems on windows
set_target_properties(${app} PROPERTIES SUFFIX ".x")
Expand All @@ -54,9 +54,9 @@ if(BUILD_APPLICATIONS)
# This minor eclipse application depends on the config parser library and
# should be moved to the libres repository - it can not be built here.
if(BUILD_ERT)
add_executable(ecl_quantile ecl/ecl_quantile.c)
target_link_libraries(ecl_quantile config)
list(APPEND apps ecl_quantile)
add_executable(rd_quantile resdata/rd_quantile.c)
target_link_libraries(rd_quantile config)
list(APPEND apps rd_quantile)
endif()
if(PTHREAD_LIBRARY)
add_executable(bls block_fs/bls.c)
Expand All @@ -75,12 +75,12 @@ if(BUILD_APPLICATIONS)
list(APPEND apps segment_info CF_dump ri_well_test)
endif()

if(BUILD_ECL_SUMMARY)
add_executable(ecl_summary ecl/view_summary.cpp)
target_link_resdata(ecl_summary)
list(APPEND apps ecl_summary)
if(BUILD_RD_SUMMARY)
add_executable(rd_summary resdata/view_summary.cpp)
target_link_resdata(rd_summary)
list(APPEND apps rd_summary)

install(FILES ${PROJECT_SOURCE_DIR}/man/man1/ecl_summary.1
install(FILES ${PROJECT_SOURCE_DIR}/man/man1/rd_summary.1
DESTINATION ${CMAKE_INSTALL_MANDIR}/man1)
endif()

Expand Down
40 changes: 20 additions & 20 deletions applications/man/man1/rd_summary.1
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
.\" First parameter, NAME, should be all caps
.\" Second parameter, SECTION, should be 1-8, maybe w/ subsection
.\" other parameters are allowed: see man(7), man(1)
.TH ecl_summary "1" "November 8 2016"
.TH rd_summary "1" "October 25 2023"
.\" Please adjust this date whenever revising the manpage.
.\"
.\" Some roff macros, for reference:
Expand All @@ -15,12 +15,12 @@
.\" .sp <n> insert n+1 empty lines
.\" for manpage-specific macros, see man(7)
.SH NAME
ecl_summary \- Program to extract summary vectors from ECLIPSE files
rd_summary \- Program to extract summary vectors from ECLIPSE files
.SH DESCRIPTION
The ecl_summary program is used to quickly extract summary vectors
The rd_summary program is used to quickly extract summary vectors
from ECLIPSE summary files. The program is invoked as:
.PP
computer> ecl_summary \fI\,/Path/to/ECLIPSE\/\fP key1 key2 key3 ....
computer> rd_summary \fI\,/Path/to/ECLIPSE\/\fP key1 key2 key3 ....
.PP
Here ECLIPSE is the name of an existing case, you can give it with
extension, or without; the case need not be in the current directory.
Expand Down Expand Up @@ -55,11 +55,11 @@ The option \fB\-\-list\fR can be used to list all available keys.
.HP
\fB\-\-no\-restart\fR: If the simulation in question is a restart, i.e a prediction
.IP
which starts at the end of the historical period, the ecl_summary
which starts at the end of the historical period, the rd_summary
program will by default also load historical data. If the \fB\-\-no\-restart\fR
option is used the program will not look for old results.
.HP
\fB\-\-no\-header\fR: By default ecl_summary will print a header line at the top, with the
\fB\-\-no\-header\fR: By default rd_summary will print a header line at the top, with the
.IP
option \fB\-\-no\-header\fR this will be suppressed.
.HP
Expand All @@ -71,38 +71,38 @@ The options should come before the ECLIPSE basename.
.PP
Example1:
.TP
computer> ecl_summary
computer> rd_summary
CASE1_XXX WWCT:F\-36 FOPT FWPT
.IP
This example will load results from case 'CASE1_XXX' and print the
results for keys 'WWCT:F\-36', 'FOPT' and 'FWPT' on standard out.
.PP
Example2:
.TP
computer> ecl_summary
computer> rd_summary
\fB\-\-list\fR CASE2_XXX "*:F\-36" "BPR:*"
.IP
This example will list all the available keys which end with
\&':F\-36' and those which start with 'BPR:'. Observe the use of
quoting characters "" when using shell wildcards.
.PP
The ecl_summary program will look for and load both unified and
The rd_summary program will look for and load both unified and
non\-unified and formatted and non\-formatted files. The default
search order is: UNSMRY, Snnnn, FUNSMRY, Annnn, however you can
manipulate this with the extension to the basename:
.PP
* If the extension corresponds to an unformatted file, ecl_summary
* If the extension corresponds to an unformatted file, rd_summary
.IP
will only look for unformatted files.
.PP
* If the extension corresponds to a unified file, ecl_summary will
* If the extension corresponds to a unified file, rd_summary will
.IP
only look for unified files.
.PP
The ecl_summary program is used to quickly extract summary vectors
The rd_summary program is used to quickly extract summary vectors
from ECLIPSE summary files. The program is invoked as:
.PP
computer> ecl_summary \fI\,/Path/to/ECLIPSE\/\fP key1 key2 key3 ....
computer> rd_summary \fI\,/Path/to/ECLIPSE\/\fP key1 key2 key3 ....
.PP
Here ECLIPSE is the name of an existing case, you can give it with
extension, or without; the case need not be in the current directory.
Expand Down Expand Up @@ -136,11 +136,11 @@ The option \fB\-\-list\fR can be used to list all available keys.
.HP
\fB\-\-no\-restart\fR: If the simulation in question is a restart, i.e a prediction
.IP
which starts at the end of the historical period, the ecl_summary
which starts at the end of the historical period, the rd_summary
program will by default also load historical data. If the \fB\-\-no\-restart\fR
option is used the program will not look for old results.
.HP
\fB\-\-no\-header\fR: By default ecl_summary will print a header line at the top, with the
\fB\-\-no\-header\fR: By default rd_summary will print a header line at the top, with the
.IP
option \fB\-\-no\-header\fR this will be suppressed.
.HP
Expand All @@ -152,31 +152,31 @@ The options should come before the ECLIPSE basename.
.PP
Example1:
.TP
computer> ecl_summary
computer> rd_summary
CASE1_XXX WWCT:F\-36 FOPT FWPT
.IP
This example will load results from case 'CASE1_XXX' and print the
results for keys 'WWCT:F\-36', 'FOPT' and 'FWPT' on standard out.
.PP
Example2:
.TP
computer> ecl_summary
computer> rd_summary
\fB\-\-list\fR CASE2_XXX "*:F\-36" "BPR:*"
.IP
This example will list all the available keys which end with
\&':F\-36' and those which start with 'BPR:'. Observe the use of
quoting characters "" when using shell wildcards.
.PP
The ecl_summary program will look for and load both unified and
The rd_summary program will look for and load both unified and
non\-unified and formatted and non\-formatted files. The default
search order is: UNSMRY, Snnnn, FUNSMRY, Annnn, however you can
manipulate this with the extension to the basename:
.PP
* If the extension corresponds to an unformatted file, ecl_summary
* If the extension corresponds to an unformatted file, rd_summary
.IP
will only look for unformatted files.
.PP
* If the extension corresponds to a unified file, ecl_summary will
* If the extension corresponds to a unified file, rd_summary will
.IP
only look for unified files.
.PP
Expand Down
Loading

0 comments on commit 22614a9

Please sign in to comment.