-
Notifications
You must be signed in to change notification settings - Fork 42
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* release/0.24.0: (93 commits) Update Changelog Version 0.24.0 clang-format ATLAS-323 atlas-io: Reduce too aggressive optimization of Cray compiler ATLAS-323 atlas-io: Avoid false positive clang-tidy errors ATLAS-323 atlas-io: Fix RecordPrinter and add test ATLAS-323 atlas-io: Support for data type 'unsigned long long' Workaround strange problem with the Fedora32 Docker image clang-format Require eckit 1.16 to support atlas-io Fix compilation with Cray ATLAS-323 atlas-io: unit test for scalars and strings ATLAS-323 atlas-io: DataType 'byte' ATLAS-323 atlas-io: Implement encoding of simple values and strings ATLAS-323 atlas-io: Support encoding of values without data section ATLAS-323 atlas-io: Compilation of GridToolsArrayView ATLAS-323 atlas-io: Compilation with intel 17 compiler (more recent was working) ATLAS-323 atlas-io: First version 0.1.0 ATLAS-323 atlas-io: util::Config::remove() and ordered util::Config::keys() ATLAS-323 atlas-io: convenience functions for atlas::vector and argument disambiguation ...
- Loading branch information
Showing
233 changed files
with
12,339 additions
and
749 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
0.22.1 | ||
0.24.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,7 @@ | ||
################################################################################ | ||
# documentation | ||
if( ENABLE_DOCS ) | ||
find_package(LATEX COMPONENTS PDFLATEX BIBTEX OPTIONAL_COMPONENTS MAKEINDEX HTLATEX) | ||
endif() | ||
|
||
ecbuild_add_option( FEATURE DOCS | ||
DESCRIPTION "Atlas documentation" | ||
DEFAULT OFF | ||
CONDITION LATEX_FOUND ) | ||
REQUIRED_PACKAGES "LATEX COMPONENTS PDFLATEX BIBTEX OPTIONAL_COMPONENTS MAKEINDEX HTLATEX" ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
### FFTW ... | ||
|
||
find_package(FFTW COMPONENTS double QUIET ) | ||
ecbuild_add_option( FEATURE FFTW | ||
DESCRIPTION "Support for fftw" | ||
CONDITION FFTW_FOUND ) | ||
REQUIRED_PACKAGES "FFTW COMPONENTS double QUIET" ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,21 @@ | ||
### trans ... | ||
|
||
ecbuild_find_package( NAME transi VERSION 0.4.4 QUIET ) | ||
if( ENABLE_TRANS OR NOT DEFINED ENABLE_TRANS ) | ||
find_package( trans 47.2 COMPONENTS transi double QUIET ) | ||
if( TARGET transi_dp ) | ||
set( transi_FOUND TRUE ) | ||
if( NOT TARGET transi ) | ||
get_target_property( transi_dp_IMPORTED transi_dp IMPORTED ) | ||
if( transi_dp_IMPORTED ) | ||
set_target_properties( transi_dp PROPERTIES IMPORTED_GLOBAL TRUE) # required for aliasing imports | ||
endif() | ||
add_library( transi ALIAS transi_dp ) | ||
endif() | ||
else() | ||
find_package( transi 0.8 QUIET ) | ||
endif() | ||
endif() | ||
|
||
ecbuild_add_option( FEATURE TRANS | ||
DESCRIPTION "Support for spectral transforms" | ||
DESCRIPTION "Support for IFS spectral transforms" | ||
CONDITION transi_FOUND ) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
|
||
Usage: | ||
|
||
atlas_DIR=<path-to-install-or-build-tree> ./build_hello_world.sh | ||
atlas_ROOT=<path-to-install-or-build-tree> ./build_hello_world.sh | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
doc/example-projects/project_hello_world_fortran/CMakeLists.txt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,108 @@ | ||
/* | ||
* (C) Copyright 2013 ECMWF. | ||
* | ||
* This software is licensed under the terms of the Apache Licence Version 2.0 | ||
* which can be obtained at http://www.apache.org/licenses/LICENSE-2.0. | ||
* In applying this licence, ECMWF does not waive the privileges and immunities | ||
* granted to it by virtue of its status as an intergovernmental organisation | ||
* nor does it submit to any jurisdiction. | ||
*/ | ||
|
||
#include <iostream> | ||
#include <string> | ||
|
||
|
||
#include "eckit/filesystem/PathName.h" | ||
|
||
#include "atlas/io/Exceptions.h" | ||
#include "atlas/io/RecordPrinter.h" | ||
#include "atlas/io/print/Bytes.h" | ||
#include "atlas/runtime/AtlasTool.h" | ||
|
||
namespace atlas { | ||
|
||
|
||
//---------------------------------------------------------------------------------------------------------------------- | ||
|
||
struct AtlasIOList : public atlas::AtlasTool { | ||
bool serial() override { return true; } | ||
int execute( const Args& args ) override; | ||
std::string briefDescription() override { return "Inspection of atlas-io files"; } | ||
std::string usage() override { return name() + " <file> [OPTION]... [--help,-h]"; } | ||
std::string longDescription() override { | ||
return "Inspection of atlas-io files\n" | ||
"\n" | ||
" <file>: path to atlas-io file"; | ||
} | ||
|
||
AtlasIOList( int argc, char** argv ) : AtlasTool( argc, argv ) { | ||
add_option( new SimpleOption<std::string>( "format", "Output format" ) ); | ||
add_option( new SimpleOption<bool>( "version", "Print version of records" ) ); | ||
add_option( new SimpleOption<bool>( "details", "Print detailed information" ) ); | ||
} | ||
}; | ||
|
||
//------------------------------------------------------------------------------------------------------ | ||
|
||
int AtlasIOList::execute( const Args& args ) { | ||
auto return_code = success(); | ||
|
||
using namespace atlas; | ||
|
||
// User sanity checks | ||
if ( args.count() == 0 ) { | ||
Log::error() << "No file specified." << std::endl; | ||
help( std::cout ); | ||
return failed(); | ||
} | ||
|
||
// Configuration | ||
util::Config config; | ||
config.set( "format", args.getString( "format", "table" ) ); | ||
config.set( "details", args.getBool( "details", false ) ); | ||
|
||
// Loop over files | ||
for ( size_t f = 0; f < args.count(); ++f ) { | ||
eckit::PathName file( args( f ) ); | ||
if ( !file.exists() ) { | ||
Log::error() << "File does not exist: " << file << std::endl; | ||
return failed(); | ||
} | ||
auto filesize = size_t( file.size() ); | ||
|
||
io::Session session; | ||
|
||
std::uint64_t pos = 0; | ||
try { | ||
while ( pos < filesize ) { | ||
auto uri = io::Record::URI{file, pos}; | ||
auto record = io::RecordPrinter{uri, config}; | ||
|
||
std::stringstream out; | ||
out << "\n# " << uri.path << " [" << uri.offset << "] " | ||
<< "{ size: " << atlas::io::Bytes{record.size()}.str( 0 ) << ", version: " << record.version() | ||
<< ", created: " << record.time() << " }"; | ||
out << '\n' << ( config.getString( "format" ) == "table" ? "" : "---" ) << '\n'; | ||
out << record << std::endl; | ||
|
||
std::cout << out.str(); | ||
|
||
pos += record.size(); | ||
} | ||
} | ||
catch ( const io::Exception& e ) { | ||
Log::error() << " ATLAS-IO-ERROR: " << e.what() << std::endl; | ||
return_code = failed(); | ||
} | ||
} | ||
return return_code; | ||
} | ||
|
||
} // namespace atlas | ||
|
||
//------------------------------------------------------------------------------------------------------ | ||
|
||
int main( int argc, char** argv ) { | ||
atlas::AtlasIOList tool( argc, argv ); | ||
return tool.start(); | ||
} |
Oops, something went wrong.