Skip to content

Commit

Permalink
[Add] WOSS Release 1.12.4
Browse files Browse the repository at this point in the history
  • Loading branch information
MetalKnight committed Dec 11, 2022
1 parent 4819ad3 commit ca5e34f
Show file tree
Hide file tree
Showing 30 changed files with 453 additions and 267 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,8 @@
***/*.trs
***/.clang-format
***/*.dirstamp
***/doc/
woss_phy/woss-phy-embeddedtcl.cc
woss/WossWOADbCreator
woss/WossDeck41DbCreator
tests/*bin
7 changes: 7 additions & 0 deletions CHANGELOG
Original file line number Diff line number Diff line change
Expand Up @@ -142,3 +142,10 @@ v1.12.1 - Fixed issue with autotools distribution.
v1.12.2 - Fixed issue with SSP::truncate c++11 syntax

v1.12.3 - New geographical to cartesian conversion model, based on spherical, GRS80 and WGS84 models

v1.12.4 - Added support for GEBCO 2022
- Fixed TCL samples
- Refactor of function member's static variables in order to guarantee re-entrancy
- Fixed bug with WossDbManager
- Added TCL debug capabilities to Altimetry classes
- Refactored usage of streams' precision throughout the whole framework
2 changes: 1 addition & 1 deletion configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@
# whose support is gratefully acknowledged.


AC_INIT([WOSS], [1.12.3], [woss@guerra-tlc.com])
AC_INIT([WOSS], [1.12.4], [woss@guerra-tlc.com])
AM_INIT_AUTOMAKE([foreign subdir-objects])

AC_MSG_NOTICE([WOSS AC_PACKAGE_VERSION])
Expand Down
14 changes: 11 additions & 3 deletions doxy/Mainpage.dox
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*
* @author Federico Guerra - federico@guerra-tlc.com
*
* @version 1.12.3
* @version 1.12.4
*
* This document provides a short techical description of the <i>World Ocean Simulation System</i> (WOSS) library
* and of its integration into <i>Multi InteRfAce Cross Layer Extension</i> (NS-Miracle).<p>
Expand Down Expand Up @@ -156,7 +156,7 @@
* from the World Ocean Atlas database of 2001 [7], 2005 [8], 2009 [9], 2013 [10] and 2018 [11]
* [woss::SspWoa2005Db, woss::SspWoa2005DbCreator];
* <li> interface implementation for the GEBCO NetCDF bathymetry databases
* (all versions: 1D, 2D, 2008, 2014, 2019, 2020) [12], [woss::BathyGebcoDb, woss::BathyGebcoDbCreator];
* (all versions: 1D, 2D, 2008, 2014, 2019, 2020, 2021, 2022) [12], [woss::BathyGebcoDb, woss::BathyGebcoDbCreator];
* <li> interface implementation and custom NetCDF data analysis taken from the DECK41 database,
* for bottom sediments composition [13], [woss::SedimDeck41Db, woss::SedimDeck41DbCreator, woss::SedimDeck41CoordDb,
* woss::SedimDeck41MarsdenDb, woss::SedimDeck41MarsdenOneDb];
Expand Down Expand Up @@ -1061,7 +1061,7 @@
* <li> If you wish to add NS-Miracle support, download the <b>latest</b> version of NS-Miracle from the official git repository as instructed <a href="http://telecom.dei.unipd.it/pages/read/58/">here</a>: \n
* Read documentation provided in the above link for installation instructions.
* <li> If you wish to use WOSS with world data, download and extract the provided databases.
* Download the <a href="https://www.bodc.ac.uk/data/open_download/gebco/gebco_2020/zip/">GEBCO 2020 2D Fifteen seconds zip archive</a>
* Download the <a href="https://www.bodc.ac.uk/data/open_download/gebco/gebco_2022/zip/">GEBCO 2022 2D Fifteen seconds zip archive</a>
* or any of the <a href="https://www.gebco.net/data_and_products/historical_data_sets">previous data sets</a>
* and put them in the same directory.
* </ul>
Expand Down Expand Up @@ -1299,6 +1299,14 @@
* <li> <b>v.1.12.3</b> <ul>
* <li> New geographical to cartesian conversion model, based on spherical, GRS80 and WGS84 models
* </ul>
* <li> <b>v.1.12.4</b> <ul>
* <li> Added support for GEBCO 2022
* <li> Fixed TCL samples
* <li> Refactor of function member's static variables in order to guarantee re-entrancy
* <li> Fixed bug with WossDbManager
* <li> Added TCL debug capabilities to Altimetry classes
* <li> Refactored usage of streams' precision throughout the whole framework
* </ul>
* </ul>
**/

Expand Down
37 changes: 20 additions & 17 deletions samples/test_aloha_hamburg_port_bathy.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -94,8 +94,8 @@ set opt(tracefile) [open $opt(tracefilename) w]
set opt(cltracefilename) "/dev/null"
set opt(cltracefile) [open $opt(cltracefilename) w]

#set opt(db_path) "insert_db_path_here"
set opt(db_path) "/home/fedwar/ns/ocean_database/dbs/"
set opt(db_path) "insert_db_path_here"
#set opt(db_path) "/home/fedwar/ns/ocean_database/dbs/"

set opt(db_res_path) "./"

Expand All @@ -105,15 +105,16 @@ if { $opt(db_path) == "insert_db_path_here" } {
}

WOSS/Definitions/RandomGenerator/NS2 set rep_number_ $opt(rep_num)
#WOSS/Definitions/RandomGenerator/C set seed_ $opt(rep_num)
WOSS/Definitions/RandomGenerator/C set seed_ $opt(rep_num)

set ssp_creator [new "WOSS/Definitions/SSP"]
set sediment_creator [new "WOSS/Definitions/Sediment"]
set pressure_creator [new "WOSS/Definitions/Pressure"]
set time_arr_creator [new "WOSS/Definitions/TimeArr"]
set time_reference [new "WOSS/Definitions/TimeReference/NS2"]
set transducer_creator [new "WOSS/Definitions/Transducer"]
set altimetry_creator [new "WOSS/Definitions/Altimetry/Bretschneider"]
set altimetry_creator [new "WOSS/Definitions/Altimetry/Flat"]
#set altimetry_creator [new "WOSS/Definitions/Altimetry/Bretschneider"]
set rand_generator [new "WOSS/Definitions/RandomGenerator/NS2"]
#set rand_generator [new "WOSS/Definitions/RandomGenerator/C"]
$rand_generator initialize
Expand Down Expand Up @@ -150,8 +151,8 @@ WOSS/Creator/Database/NetCDF/Sediment/DECK41 set woss_db_debug 0
set db_sedim [new "WOSS/Creator/Database/NetCDF/Sediment/DECK41"]
$db_sedim setDeck41DbTypeV2
$db_sedim setUpDeck41CoordinatesDb "${opt(db_path)}/seafloor_sediment/DECK41_V2_coordinates.nc"
$db_sedim setUpDeck41MarsdenDb "${opt(db_path)}/seafloor_sediment/DECK41_V2_mardsen_square.nc"
$db_sedim setUpDeck41MarsdenOneDb "${opt(db_path)}/seafloor_sediment/DECK41_V2_mardsen_one_degree.nc"
$db_sedim setUpDeck41MarsdenDb "${opt(db_path)}/seafloor_sediment/DECK41_V2_marsden_square.nc"
$db_sedim setUpDeck41MarsdenOneDb "${opt(db_path)}/seafloor_sediment/DECK41_V2_marsden_one_degree.nc"


WOSS/Creator/Database/NetCDF/SSP/WOA2013/MonthlyAverage set debug 0
Expand All @@ -176,28 +177,30 @@ set db_bathy [new "WOSS/Creator/Database/Textual/Bathymetry/UMT_CSV"]
$db_bathy setDbPathName "${opt(db_path)}/bathymetry/hamburg_port.csv"


WOSS/Database/Manager set debug 0

WOSS/Definitions/Altimetry/Flat set evolution_time_quantum -1
WOSS/Definitions/Altimetry/Flat set range -1
WOSS/Definitions/Altimetry/Flat set total_range_steps -1
WOSS/Definitions/Altimetry/Flat set depth 0.0
set cust_altimetry [new "WOSS/Definitions/Altimetry/Flat"]

# WOSS/Definitions/Altimetry/Bretschneider set evolution_time_quantum -1
# WOSS/Definitions/Altimetry/Bretschneider set range -1
# WOSS/Definitions/Altimetry/Bretschneider set total_range_steps 3000
# WOSS/Definitions/Altimetry/Bretschneider set characteristic_height 1.5
# WOSS/Definitions/Altimetry/Bretschneider set average_period 3.0
# set cust_altimetry [new "WOSS/Definitions/Altimetry/Bretschneider"]
#WOSS/Definitions/Altimetry/Bretschneider set evolution_time_quantum -1
#WOSS/Definitions/Altimetry/Bretschneider set range -1
#WOSS/Definitions/Altimetry/Bretschneider set total_range_steps -1
#WOSS/Definitions/Altimetry/Bretschneider set characteristic_height 1.5
#WOSS/Definitions/Altimetry/Bretschneider set average_period 3.0
#set cust_altimetry [new "WOSS/Definitions/Altimetry/Bretschneider"]

$cust_altimetry setDebug 0


#first ssp, time key is 1st january 2011, 9:01 am
set time_evo_ssp_1 [new "WOSS/Definitions/Time"]
$time_evo_ssp_1 setTime 1 1 2011 9 0 1

WOSS/Database/Manager set debug 0
set db_manager [new "WOSS/Database/Manager"]
$db_manager setCustomSSP $time_evo_ssp_1 "./ssp-custom-hamb-port.txt"
# $db_manager setCustomAltimetry $cust_altimetry
$db_manager setCustomAltimetry $cust_altimetry

WOSS/Creator/Bellhop set debug 0.0
WOSS/Creator/Bellhop set woss_debug 0.0
Expand Down Expand Up @@ -226,7 +229,7 @@ WOSS/Creator/Bellhop set box_range 15000


set woss_creator [new "WOSS/Creator/Bellhop"]
$woss_creator setWorkDirPath "./bellhop_out_hamburg_port/"
$woss_creator setWorkDirPath "/dev/shm/woss/bellhop_out_hamburg_port/"
$woss_creator setBellhopPath ""
$woss_creator setBellhopMode 0 0 "A"
$woss_creator setBeamOptions 0 0 "B"
Expand Down Expand Up @@ -262,7 +265,7 @@ set woss_controller [new "WOSS/Controller"]
$woss_controller setBathymetryDbCreator $db_bathy
$woss_controller setSedimentDbCreator $db_sedim
#$woss_controller setSSPDbCreator $db_ssp
$woss_controller setTimeArrResultsDbCreator $db_res_arr
#$woss_controller setTimeArrResultsDbCreator $db_res_arr
$woss_controller setWossDbManager $db_manager
$woss_controller setWossManager $woss_manager
$woss_controller setWossCreator $woss_creator
Expand Down
46 changes: 24 additions & 22 deletions samples/test_aloha_no_dbs.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -108,12 +108,12 @@ set ssp_creator [new "WOSS/Definitions/SSP"]
set sediment_creator [new "WOSS/Definitions/Sediment"]
set pressure_creator [new "WOSS/Definitions/Pressure"]
set time_arr_creator [new "WOSS/Definitions/TimeArr"]
set altimetry_creator [new "WOSS/Definitions/Altimetry/Bretschneider"]
# set altimetry_creator [new "WOSS/Definitions/Altimetry/Flat"]
#set altimetry_creator [new "WOSS/Definitions/Altimetry/Bretschneider"]
set altimetry_creator [new "WOSS/Definitions/Altimetry/Flat"]
set time_reference [new "WOSS/Definitions/TimeReference/NS2"]
set transducer_creator [new "WOSS/Definitions/Transducer"]
# set rand_generator [new "WOSS/Definitions/RandomGenerator/NS2"]
set rand_generator [new "WOSS/Definitions/RandomGenerator/C"]
set rand_generator [new "WOSS/Definitions/RandomGenerator/NS2"]
#set rand_generator [new "WOSS/Definitions/RandomGenerator/C"]
$rand_generator initialize

#### we plug the chosen prototypes into the woss::DefinitionHandler
Expand Down Expand Up @@ -145,26 +145,27 @@ set db_res_arr [new "WOSS/Creator/Database/Binary/Results/TimeArr"]
$db_res_arr setDbPathName "${opt(db_res_path)}/test_aloha_no_dbs_res_arr.dat"


WOSS/Database/Manager set debug 0

WOSS/Definitions/Altimetry/Flat set evolution_time_quantum -1
WOSS/Definitions/Altimetry/Flat set range -1
WOSS/Definitions/Altimetry/Flat set total_range_steps -1
WOSS/Definitions/Altimetry/Flat set depth 0.0
set cust_altimetry [new "WOSS/Definitions/Altimetry/Flat"]

# WOSS/Definitions/Altimetry/Bretschneider set evolution_time_quantum -1
# WOSS/Definitions/Altimetry/Bretschneider set range -1
# WOSS/Definitions/Altimetry/Bretschneider set total_range_steps 3000
# WOSS/Definitions/Altimetry/Bretschneider set characteristic_height 1.5
# WOSS/Definitions/Altimetry/Bretschneider set average_period 3.0
# set cust_altimetry [new "WOSS/Definitions/Altimetry/Bretschneider"]
#WOSS/Definitions/Altimetry/Bretschneider set evolution_time_quantum -1
#WOSS/Definitions/Altimetry/Bretschneider set range -1
#WOSS/Definitions/Altimetry/Bretschneider set total_range_steps -1
#WOSS/Definitions/Altimetry/Bretschneider set characteristic_height 1.5
#WOSS/Definitions/Altimetry/Bretschneider set average_period 3.0
#set cust_altimetry [new "WOSS/Definitions/Altimetry/Bretschneider"]

$cust_altimetry setDebug 0

#### We create the mandatory woss::WossDbManager and we set a custom sediment and SSP for ALL
#### the channel computations involved.
#### we also create a custom bathymetry: it is a line that starts at ($opt(start_lat), $opt(start_long)), it is valid
#### for all bearings, and has four range/depth points. WossDbManager will provide bathymetry for (lat, long) points
#### selecting the closest point from its custom bathymetry.
WOSS/Database/Manager set debug 0
set db_manager [new "WOSS/Database/Manager"]
$db_manager setCustomSediment "Test Sedim" 1560 200 1.5 0.9 0.8 1.0
$db_manager setCustomAltimetry $cust_altimetry
Expand Down Expand Up @@ -212,16 +213,16 @@ $woss_creator setSimulationTimes 0 0 1 12 2009 0 0 1 1 12 2009 0 0 1
### choose between single-threaded or multithreaded WossManager
### by uncomment/comment the followings lines

WOSS/Manager/Simple set debug 0
WOSS/Manager/Simple set is_time_evolution_active -1.0
WOSS/Manager/Simple set space_sampling 0.0
set woss_manager [new "WOSS/Manager/Simple"]
#WOSS/Manager/Simple set debug 0
#WOSS/Manager/Simple set is_time_evolution_active -1.0
#WOSS/Manager/Simple set space_sampling 0.0
#set woss_manager [new "WOSS/Manager/Simple"]

#WOSS/Manager/Simple/MultiThread set debug 0.0
#WOSS/Manager/Simple/MultiThread set is_time_evolution_active -1.0
#WOSS/Manager/Simple/MultiThread set space_sampling 0.0
#WOSS/Manager/Simple/MultiThread set concurrent_threads 0
#set woss_manager [new "WOSS/Manager/Simple/MultiThread"]
WOSS/Manager/Simple/MultiThread set debug 0.0
WOSS/Manager/Simple/MultiThread set is_time_evolution_active -1.0
WOSS/Manager/Simple/MultiThread set space_sampling 0.0
WOSS/Manager/Simple/MultiThread set concurrent_threads 0
set woss_manager [new "WOSS/Manager/Simple/MultiThread"]


#### we create the mandatory woss::TransducerHandler
Expand All @@ -232,7 +233,8 @@ set transducer_handler [new "WOSS/Definitions/TransducerHandler"]
#### we connect everything to the woss::WossController and we initialize it
WOSS/Controller set debug 0
set woss_controller [new "WOSS/Controller"]
$woss_controller setTimeArrResultsDbCreator $db_res_arr
#uncomment if you wish to store results to a db on filesystem
#$woss_controller setTimeArrResultsDbCreator $db_res_arr
$woss_controller setWossDbManager $db_manager
$woss_controller setWossManager $woss_manager
$woss_controller setWossCreator $woss_creator
Expand Down
45 changes: 31 additions & 14 deletions samples/test_aloha_no_dbs_waypoints.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -113,9 +113,8 @@ set opt(tx_margin_db) 10.0
set opt(node_bathy_offset) -2.0
set opt(auv_depth) 10.0


# set opt(db_path) "insert_db_path_here"
set opt(db_path) "/home/fedwar/ns/ocean_database/"
set opt(db_path) "insert_db_path_here"
#set opt(db_path) "/home/fedwar/ns/ocean_database/dbs/"
set opt(db_res_path) "."

if { $opt(db_path) == "insert_db_path_here" } {
Expand Down Expand Up @@ -180,9 +179,10 @@ set pressure_creator [new "WOSS/Definitions/Pressure"]
set time_arr_creator [new "WOSS/Definitions/TimeArr"]
set time_reference [new "WOSS/Definitions/TimeReference/NS2"]
set transducer_creator [new "WOSS/Definitions/Transducer"]
set altimetry_creator [new "WOSS/Definitions/Altimetry/Bretschneider"]
# set rand_generator [new "WOSS/Definitions/RandomGenerator/NS2"]
set rand_generator [new "WOSS/Definitions/RandomGenerator/C"]
set altimetry_creator [new "WOSS/Definitions/Altimetry/Flat"]
#set altimetry_creator [new "WOSS/Definitions/Altimetry/Bretschneider"]
set rand_generator [new "WOSS/Definitions/RandomGenerator/NS2"]
#set rand_generator [new "WOSS/Definitions/RandomGenerator/C"]
$rand_generator initialize

set def_handler [new "WOSS/Definitions/Handler"]
Expand Down Expand Up @@ -217,9 +217,26 @@ WOSS/Creator/Database/NetCDF/Sediment/DECK41 set debug 0
WOSS/Creator/Database/NetCDF/Sediment/DECK41 set woss_db_debug 0


WOSS/Definitions/Altimetry/Flat set evolution_time_quantum -1
WOSS/Definitions/Altimetry/Flat set range -1
WOSS/Definitions/Altimetry/Flat set total_range_steps -1
WOSS/Definitions/Altimetry/Flat set depth 0.0
set cust_altimetry [new "WOSS/Definitions/Altimetry/Flat"]

#WOSS/Definitions/Altimetry/Bretschneider set evolution_time_quantum -1
#WOSS/Definitions/Altimetry/Bretschneider set range -1
#WOSS/Definitions/Altimetry/Bretschneider set total_range_steps -1
#WOSS/Definitions/Altimetry/Bretschneider set characteristic_height 1.5
#WOSS/Definitions/Altimetry/Bretschneider set average_period 3.0
#set cust_altimetry [new "WOSS/Definitions/Altimetry/Bretschneider"]

$cust_altimetry setDebug 0


WOSS/Database/Manager set debug 0
set db_manager [new WOSS/Database/Manager]
$db_manager setCustomSediment "Test Sedim" 1560 200 1.5 0.9 0.8 1.0
$db_manager setCustomAltimetry $cust_altimetry
$db_manager setCustomSSP 0 "./ssp-test.txt"


Expand Down Expand Up @@ -257,14 +274,14 @@ $woss_creator setAltimetryType 0 0 "L"
$woss_creator setSimulationTimes 0 0 1 1 2010 0 0 1 2 1 2010 0 0 1


WOSS/Manager/Simple set debug 0
WOSS/Manager/Simple set space_sampling 2.0
set woss_manager [new "WOSS/Manager/Simple"]
#WOSS/Manager/Simple set debug 0
#WOSS/Manager/Simple set space_sampling 2.0
#set woss_manager [new "WOSS/Manager/Simple"]

#WOSS/Manager/Simple/MultiThread set debug 0
#WOSS/Manager/Simple/MultiThread set space_sampling 2.0
#WOSS/Manager/Simple/MultiThread set concurrent_threads 0.0
#set woss_manager [new "WOSS/Manager/Simple/MultiThread"]
WOSS/Manager/Simple/MultiThread set debug 0
WOSS/Manager/Simple/MultiThread set space_sampling 2.0
WOSS/Manager/Simple/MultiThread set concurrent_threads 0.0
set woss_manager [new "WOSS/Manager/Simple/MultiThread"]


WOSS/Definitions/TransducerHandler set debug 0
Expand All @@ -276,7 +293,7 @@ $transducer_handler importAscii "ITC-3001" "$opt(db_path)/transducers/ITC/ITC-IT

WOSS/Controller set debug 0
set woss_controller [new WOSS/Controller]
$woss_controller setTimeArrResultsDbCreator $db_res_arr
#$woss_controller setTimeArrResultsDbCreator $db_res_arr
$woss_controller setWossDbManager $db_manager
$woss_controller setWossManager $woss_manager
$woss_controller setWossCreator $woss_creator
Expand Down
Loading

0 comments on commit ca5e34f

Please sign in to comment.