Mads.jl

Mads.jl functions:

Mads.MFlmMethod

Matrix Factorization using Levenberg Marquardt

Methods:

  • Mads.MFlm(X::AbstractMatrix{T}, nk::Integer; method, log_W, log_H, retries, initW, initH, tolX, tolG, tolOF, tolOFcount, minOF, maxEval, maxIter, maxJacobians, lambda, lambda_mu, np_lambda, show_trace, quiet) where T<:Number : /home/travis/build/madsjulia/Mads.jl/src/MadsBlindSourceSeparation.jl:136
  • Mads.MFlm(X::AbstractMatrix{T}, range::AbstractRange{Int64}; kw...) where T<:Number : /home/travis/build/madsjulia/Mads.jl/src/MadsBlindSourceSeparation.jl:103

Arguments:

  • X::AbstractMatrix{T} : matrix to factorize
  • nk::Integer : number of features to extract
  • range::AbstractRange{Int64}

Keywords:

  • initH : initial H (feature) matrix
  • initW : initial W (weight) matrix
  • lambda
  • lambda_mu
  • log_H : log-transform H (feature) matrix[default=false]
  • log_W : log-transform W (weight) matrix [default=false]
  • maxEval
  • maxIter
  • maxJacobians
  • method
  • minOF
  • np_lambda
  • quiet
  • retries : number of solution retries [default=1]
  • show_trace
  • tolG : parameter space update tolerance [default=1e-6]
  • tolOF : objective function update tolerance [default=1e-3]
  • tolOFcount : number of Jacobian runs with small objective function change [default=5]
  • tolX

Returns:

  • NMF results
source
Mads.NMFipoptFunction

Non-negative Matrix Factorization using JuMP/Ipopt

Methods:

  • Mads.NMFipopt(X::AbstractMatrix, nk::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsBlindSourceSeparation.jl:60
  • Mads.NMFipopt(X::AbstractMatrix, nk::Integer, retries::Integer; random, maxiter, maxguess, initW, initH, verbosity, quiet) : /home/travis/build/madsjulia/Mads.jl/src/MadsBlindSourceSeparation.jl:60

Arguments:

  • X::AbstractMatrix : matrix to factorize
  • nk::Integer : number of features to extract
  • retries::Integer : number of solution retries [default=1]

Keywords:

  • initH : initial H (feature) matrix
  • initW : initial W (weight) matrix
  • maxguess : guess about the maximum for the H (feature) matrix [default=1]
  • maxiter : maximum number of iterations [default=100000]
  • quiet : quiet [default=false]
  • random : random initial guesses [default=false]
  • verbosity : verbosity output level [default=0]

Returns:

  • NMF results
source
Mads.NMFmFunction

Non-negative Matrix Factorization using NMF

Methods:

  • Mads.NMFm(X::Array, nk::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsBlindSourceSeparation.jl:21
  • Mads.NMFm(X::Array, nk::Integer, retries::Integer; tol, maxiter) : /home/travis/build/madsjulia/Mads.jl/src/MadsBlindSourceSeparation.jl:21

Arguments:

  • X::Array : matrix to factorize
  • nk::Integer : number of features to extract
  • retries::Integer : number of solution retries [default=1]

Keywords:

  • maxiter : maximum number of iterations [default=10000]
  • tol : solution tolerance [default=1.0e-9]

Returns:

  • NMF results
source
Mads.addkeyword!Function

Add a keyword in a class within the Mads dictionary madsdata

Methods:

  • Mads.addkeyword!(madsdata::AbstractDict, class::AbstractString, keyword::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:314
  • Mads.addkeyword!(madsdata::AbstractDict, keyword::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:310

Arguments:

  • class::AbstractString : dictionary class; if not provided searches for keyword in Problem class
  • keyword::AbstractString : dictionary key
  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.addsource!Function

Add an additional contamination source

Methods:

  • Mads.addsource!(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsAnasol.jl:17
  • Mads.addsource!(madsdata::AbstractDict, sourceid::Int64; dict) : /home/travis/build/madsjulia/Mads.jl/src/MadsAnasol.jl:17

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • sourceid::Int64 : source id [default=0]

Keywords:

  • dict
source
Mads.addsourceparameters!Method

Add contaminant source parameters

Methods:

  • Mads.addsourceparameters!(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsAnasol.jl:74

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.allwellsoff!Method

Turn off all the wells in the MADS problem dictionary

Methods:

  • Mads.allwellsoff!(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:618

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.allwellson!Method

Turn on all the wells in the MADS problem dictionary

Methods:

  • Mads.allwellson!(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:560

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.amanziFunction

Execute Amanzi external groundwater flow and transport simulator

Methods:

  • Mads.amanzi(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsSimulators.jl:12
  • Mads.amanzi(filename::AbstractString, nproc::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsSimulators.jl:12
  • Mads.amanzi(filename::AbstractString, nproc::Int64, quiet::Bool) : /home/travis/build/madsjulia/Mads.jl/src/MadsSimulators.jl:12
  • Mads.amanzi(filename::AbstractString, nproc::Int64, quiet::Bool, observation_filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsSimulators.jl:12
  • Mads.amanzi(filename::AbstractString, nproc::Int64, quiet::Bool, observation_filename::AbstractString, setup::AbstractString; amanzi_exe) : /home/travis/build/madsjulia/Mads.jl/src/MadsSimulators.jl:12

Arguments:

  • filename::AbstractString : amanzi input file name
  • nproc::Int64 : number of processor to be used by Amanzi [default=Mads.nprocs_per_task_default]
  • observation_filename::AbstractString : Amanzi observation file name [default="observations.out"]
  • quiet::Bool : suppress output [default=Mads.quiet]
  • setup::AbstractString : bash script to setup Amanzi environmental variables [default="source-amanzi-setup"]

Keywords:

  • amanzi_exe : full path to the Amanzi executable
source
Mads.amanzi_output_parserFunction

Parse Amanzi output provided in an external file (filename)

Methods:

  • Mads.amanzi_output_parser() : /home/travis/build/madsjulia/Mads.jl/src/MadsParsers.jl:20
  • Mads.amanzi_output_parser(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsParsers.jl:20

Arguments:

  • filename::AbstractString : external file name [default="observations.out"]

Returns:

  • dictionary with model observations following MADS requirements

Example:

Mads.amanzi_output_parser()
Mads.amanzi_output_parser("observations.out")
source
Mads.asinetransformFunction

Arcsine transformation of model parameters

Methods:

  • Mads.asinetransform(madsdata::AbstractDict, params::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsSineTransformations.jl:1
  • Mads.asinetransform(params::AbstractVector, lowerbounds::AbstractVector, upperbounds::AbstractVector, indexlogtransformed::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsSineTransformations.jl:11

Arguments:

  • indexlogtransformed::AbstractVector : index vector of log-transformed parameters
  • lowerbounds::AbstractVector : lower bounds
  • madsdata::AbstractDict : MADS problem dictionary
  • params::AbstractVector : model parameters
  • upperbounds::AbstractVector : upper bounds

Returns:

  • Arcsine transformation of model parameters
source
Mads.bigdtMethod

Perform Bayesian Information Gap Decision Theory (BIG-DT) analysis

Methods:

  • Mads.bigdt(madsdata::AbstractDict, nummodelruns::Int64; numhorizons, maxHorizon, numlikelihoods) : /home/travis/build/madsjulia/Mads.jl/src/MadsBayesInfoGap.jl:121

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • nummodelruns::Int64 : number of model runs

Keywords:

  • maxHorizon : maximum info-gap horizons of uncertainty [default=3]
  • numhorizons : number of info-gap horizons of uncertainty [default=100]
  • numlikelihoods : number of Bayesian likelihoods [default=25]

Returns:

  • dictionary with BIG-DT results
source
Mads.boundparameters!Function

Bound model parameters based on their ranges

Methods:

  • Mads.boundparameters!(madsdata::AbstractDict, pardict::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:817
  • Mads.boundparameters!(madsdata::AbstractDict, parvec::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:805

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • pardict::AbstractDict : Parameter dictionary
  • parvec::AbstractVector : Parameter vector
source
Mads.calibrateMethod

Calibrate Mads model using a constrained Levenberg-Marquardt technique

Mads.calibrate(madsdata; tolX=1e-3, tolG=1e-6, maxEval=1000, maxIter=100, maxJacobians=100, lambda=100.0, lambda_mu=10.0, np_lambda=10, show_trace=false, usenaive=false)

Methods:

  • Mads.calibrate(madsdata::AbstractDict; tolX, tolG, tolOF, tolOFcount, minOF, maxEval, maxIter, maxJacobians, lambda, lambda_mu, np_lambda, show_trace, quiet, usenaive, save_results, localsa, parallel_optimization) : /home/travis/build/madsjulia/Mads.jl/src/MadsCalibrate.jl:195

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • lambda : initial Levenberg-Marquardt lambda [default=100.0]
  • lambda_mu : lambda multiplication factor [default=10.0]
  • localsa : perform local sensitivity analysis [default=false]
  • maxEval : maximum number of model evaluations [default=1000]
  • maxIter : maximum number of optimization iterations [default=100]
  • maxJacobians : maximum number of Jacobian solves [default=100]
  • minOF : objective function update tolerance [default=1e-3]
  • np_lambda : number of parallel lambda solves [default=10]
  • parallel_optimization
  • quiet
  • save_results : save intermediate results [default=true]
  • show_trace : shows solution trace [default=false]
  • tolG : parameter space update tolerance [default=1e-6]
  • tolOF : objective function update tolerance [default=1e-3]
  • tolOFcount : number of Jacobian runs with small objective function change [default=5]
  • tolX : parameter space tolerance [default=1e-4]
  • usenaive : use naive Levenberg-Marquardt solver [default=false]

Returns:

  • model parameter dictionary with the optimal values at the minimum
  • optimization algorithm results (e.g. results.minimizer)
source
Mads.calibraterandomFunction

Calibrate with random initial guesses

Methods:

  • Mads.calibraterandom(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsCalibrate.jl:43
  • Mads.calibraterandom(madsdata::AbstractDict, numberofsamples::Integer; tolX, tolG, tolOF, tolOFcount, minOF, maxEval, maxIter, maxJacobians, lambda, lambda_mu, np_lambda, show_trace, usenaive, seed, rng, quiet, all, save_results, first_init) : /home/travis/build/madsjulia/Mads.jl/src/MadsCalibrate.jl:43

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • numberofsamples::Integer : number of random initial samples [default=1]

Keywords:

  • all : all model results are returned [default=false]
  • first_init
  • lambda : initial Levenberg-Marquardt lambda [default=100.0]
  • lambda_mu : lambda multiplication factor [default=10.0]
  • maxEval : maximum number of model evaluations [default=1000]
  • maxIter : maximum number of optimization iterations [default=100]
  • maxJacobians : maximum number of Jacobian solves [default=100]
  • minOF
  • np_lambda : number of parallel lambda solves [default=10]
  • quiet : [default=true]
  • rng
  • save_results : save intermediate results [default=true]
  • seed : random seed [default=0]
  • show_trace : shows solution trace [default=false]
  • tolG : parameter space update tolerance [default=1e-6]
  • tolOF : objective function update tolerance [default=1e-3]
  • tolOFcount : number of Jacobian runs with small objective function change [default=5]
  • tolX : parameter space tolerance [default=1e-4]
  • usenaive : use naive Levenberg-Marquardt solver [default=false]

Returns:

  • model parameter dictionary with the optimal values at the minimum
  • optimization algorithm results (e.g. bestresult[2].minimizer)

Example:

Mads.calibraterandom(madsdata; tolX=1e-3, tolG=1e-6, maxEval=1000, maxIter=100, maxJacobians=100, lambda=100.0, lambda_mu=10.0, np_lambda=10, show_trace=false, usenaive=false)
Mads.calibraterandom(madsdata, numberofsamples; tolX=1e-3, tolG=1e-6, maxEval=1000, maxIter=100, maxJacobians=100, lambda=100.0, lambda_mu=10.0, np_lambda=10, show_trace=false, usenaive=false)
source
Mads.calibraterandom_parallelFunction

Calibrate with random initial guesses in parallel

Methods:

  • Mads.calibraterandom_parallel(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsCalibrate.jl:119
  • Mads.calibraterandom_parallel(madsdata::AbstractDict, numberofsamples::Integer; tolX, tolG, tolOF, tolOFcount, minOF, maxEval, maxIter, maxJacobians, lambda, lambda_mu, np_lambda, show_trace, usenaive, seed, rng, quiet, save_results, first_init, localsa, all_results) : /home/travis/build/madsjulia/Mads.jl/src/MadsCalibrate.jl:119

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • numberofsamples::Integer : number of random initial samples [default=1]

Keywords:

  • all_results
  • first_init
  • lambda : initial Levenberg-Marquardt lambda [default=100.0]
  • lambda_mu : lambda multiplication factor [default=10.0]
  • localsa : perform local sensitivity analysis [default=false]
  • maxEval : maximum number of model evaluations [default=1000]
  • maxIter : maximum number of optimization iterations [default=100]
  • maxJacobians : maximum number of Jacobian solves [default=100]
  • minOF
  • np_lambda : number of parallel lambda solves [default=10]
  • quiet : suppress output [default=true]
  • rng
  • save_results : save intermediate results [default=true]
  • seed : random seed [default=0]
  • show_trace : shows solution trace [default=false]
  • tolG : parameter space update tolerance [default=1e-6]
  • tolOF : objective function update tolerance [default=1e-3]
  • tolOFcount : number of Jacobian runs with small objective function change [default=5]
  • tolX : parameter space tolerance [default=1e-4]
  • usenaive : use naive Levenberg-Marquardt solver [default=false]

Returns:

  • vector with all objective function values
  • boolean vector (converged/not converged)
  • array with estimate model parameters
source
Mads.captureoffMethod

Make MADS not capture

Methods:

  • Mads.captureoff() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:148
source
Mads.captureonMethod

Make MADS capture

Methods:

  • Mads.captureon() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:139
source
Mads.checkmodeloutputdirsMethod

Check the directories where model outputs should be saved for MADS

Methods:

  • Mads.checkmodeloutputdirs(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:766

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • true or false
source
Mads.checknodedirFunction

Check if a directory is readable

Methods:

  • Mads.checknodedir(dir::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsExecute.jl:10
  • Mads.checknodedir(dir::AbstractString, waittime::Float64) : /home/travis/build/madsjulia/Mads.jl/src/MadsExecute.jl:10
  • Mads.checknodedir(node::AbstractString, dir::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsExecute.jl:1
  • Mads.checknodedir(node::AbstractString, dir::AbstractString, waittime::Float64) : /home/travis/build/madsjulia/Mads.jl/src/MadsExecute.jl:1

Arguments:

  • dir::AbstractString : directory
  • node::AbstractString : computational node name (e.g. madsmax, wf03, or 127.0.0.1)
  • waittime::Float64 : wait time in seconds [default=10]

Returns:

  • true if the directory is readable, false otherwise
source
Mads.checkobservationrangesMethod

Check parameter ranges for model parameters

Methods:

  • Mads.checkobservationranges(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:811

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.checkoutFunction

Checkout (pull) the latest version of Mads modules

Methods:

  • Mads.checkout() : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:107
  • Mads.checkout(modulename::AbstractString; git, master, force, pull, required, all) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:107

Arguments:

  • modulename::AbstractString : module name

Keywords:

  • all : whether to checkout all the modules [default=false]
  • force : whether to overwrite local changes when checkout [default=false]
  • git : whether to use "git checkout" [default=true]
  • master : whether on master branch [default=false]
  • pull : whether to run "git pull" [default=true]
  • required : whether only checkout Mads.required modules [default=false]
source
Mads.checkparameterrangesMethod

Check parameter ranges for model parameters

Methods:

  • Mads.checkparameterranges(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:741

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.cleancoverageMethod

Remove Mads coverage files

Methods:

  • Mads.cleancoverage() : /home/travis/build/madsjulia/Mads.jl/src/MadsTest.jl:22
source
Mads.cmadsins_obsMethod

Call C MADS ins_obs() function from MADS dynamic library

Methods:

  • Mads.cmadsins_obs(obsid::AbstractVector, instructionfilename::AbstractString, inputfilename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsCMads.jl:38

Arguments:

  • inputfilename::AbstractString : input file name
  • instructionfilename::AbstractString : instruction file name
  • obsid::AbstractVector : observation id

Return:

  • observations
source
Mads.commitFunction

Commit the latest version of Mads modules in the repository

Methods:

  • Mads.commit(commitmsg::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:255
  • Mads.commit(commitmsg::AbstractString, modulename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:255

Arguments:

  • commitmsg::AbstractString : commit message
  • modulename::AbstractString : module name
source
Mads.computemassFunction

Compute injected/reduced contaminant mass (for a given set of mads input files when "path" is provided)

Methods:

  • Mads.computemass(madsdata::AbstractDict; time) : /home/travis/build/madsjulia/Mads.jl/src/MadsAnasol.jl:463
  • Mads.computemass(madsfiles::Union{Regex, String}; time, path) : /home/travis/build/madsjulia/Mads.jl/src/MadsAnasol.jl:490

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • madsfiles::Union{Regex, String} : matching pattern for Mads input files (string or regular expression accepted)

Keywords:

  • path : search directory for the mads input files [default="."]
  • time : computational time [default=0]

Returns:

  • array with all the lambda values
  • array with associated total injected mass
  • array with associated total reduced mass

Example:

Mads.computemass(madsfiles; time=0, path=".")
source
Mads.computeparametersensititiesMethod

Compute sensitivities for each model parameter; averaging the sensitivity indices over the entire observation range

Methods:

  • Mads.computeparametersensitities(madsdata::AbstractDict, saresults::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:867

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • saresults::AbstractDict : dictionary with sensitivity analysis results
source
Mads.contaminationMethod

Compute concentration for a point in space and time (x,y,z,t)

Methods:

  • Mads.contamination(wellx::Number, welly::Number, wellz::Number, n::Number, lambda::Number, theta::Number, vx::Number, vy::Number, vz::Number, ax::Number, ay::Number, az::Number, H::Number, x::Number, y::Number, z::Number, dx::Number, dy::Number, dz::Number, f::Number, t0::Number, t1::Number, t::AbstractVector, anasolfunction::Function) : /home/travis/build/madsjulia/Mads.jl/src/MadsAnasol.jl:433

Arguments:

  • H::Number : Hurst coefficient for Fractional Brownian dispersion
  • anasolfunction::Function
  • ax::Number : dispersivity in X direction (longitudinal)
  • ay::Number : dispersivity in Y direction (transverse horizontal)
  • az::Number : dispersivity in Y direction (transverse vertical)
  • dx::Number : source size (extent) in X direction
  • dy::Number : source size (extent) in Y direction
  • dz::Number : source size (extent) in Z direction
  • f::Number : source mass flux
  • lambda::Number : first-order reaction rate
  • n::Number : porosity
  • t0::Number : source starting time
  • t1::Number : source termination time
  • t::AbstractVector : vector of times to compute concentration at the observation point
  • theta::Number : groundwater flow direction
  • vx::Number : advective transport velocity in X direction
  • vy::Number : advective transport velocity in Y direction
  • vz::Number : advective transport velocity in Z direction
  • wellx::Number : observation point (well) X coordinate
  • welly::Number : observation point (well) Y coordinate
  • wellz::Number : observation point (well) Z coordinate
  • x::Number : X coordinate of contaminant source location
  • y::Number : Y coordinate of contaminant source location
  • z::Number : Z coordinate of contaminant source location

Returns:

  • a vector of predicted concentration at (wellx, welly, wellz, t)
source
Mads.copyaquifer2sourceparameters!Method

Copy aquifer parameters to become contaminant source parameters

Methods:

  • Mads.copyaquifer2sourceparameters!(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsAnasol.jl:113

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.copyrightMethod

Produce MADS copyright information

Methods:

  • Mads.copyright() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelp.jl:44
source
Mads.create_tests_offMethod

Turn off the generation of MADS tests (default)

Methods:

  • Mads.create_tests_off() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:193
source
Mads.create_tests_onMethod

Turn on the generation of MADS tests (dangerous)

Methods:

  • Mads.create_tests_on() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:184
source
Mads.createobservationsFunction

Create Mads dictionary of observations and instruction file

Methods:

  • Mads.createobservations(nrow::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:25
  • Mads.createobservations(nrow::Int64, ncol::Int64; obstring, pretext, prestring, poststring, filename) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:25
  • Mads.createobservations(obs::AbstractMatrix; key, weight, time) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:80
  • Mads.createobservations(obs::AbstractVector; key, weight, time, min, max, minorig, maxorig, dist, distribution) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:43

Arguments:

  • ncol::Int64 : number of columns [default 1]
  • nrow::Int64 : number of rows
  • obs::AbstractMatrix
  • obs::AbstractVector

Keywords:

  • dist
  • distribution
  • filename : file name
  • key
  • max
  • maxorig
  • min
  • minorig
  • obstring : observation string
  • poststring : post instruction file string
  • prestring : pre instruction file string
  • pretext : preamble instructions
  • time
  • weight

)

Returns:

  • observation dictionary
source
Mads.createobservations!Function

Create observations in the MADS problem dictionary based on time and observation vectors

Methods:

  • Mads.createobservations!(madsdata::AbstractDict, observation::AbstractDict; logtransform, weight_type, weight) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:499
  • Mads.createobservations!(madsdata::AbstractDict, time::AbstractVector, observation::AbstractVector; logtransform, weight_type, weight) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:455
  • Mads.createobservations!(md::AbstractDict, obs::AbstractVecOrMat; kw...) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:115

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • md::AbstractDict
  • obs::AbstractVecOrMat
  • observation::AbstractDict : dictionary of observations
  • observation::AbstractVector : dictionary of observations
  • time::AbstractVector : vector of observation times

Keywords:

  • logtransform : log transform observations [default=false]
  • weight : weight value [default=1]
  • weight_type : weight type [default=constant]
source
Mads.createproblemFunction

Create a new Mads problem where the observation targets are computed based on the model predictions

Methods:

  • Mads.createproblem(in::Integer, out::Integer, f::Union{AbstractString, Function}; kw...) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:223
  • Mads.createproblem(infilename::AbstractString, outfilename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:237
  • Mads.createproblem(madsdata::AbstractDict, outfilename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:262
  • Mads.createproblem(madsdata::AbstractDict, predictions::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:273
  • Mads.createproblem(madsdata::AbstractDict, predictions::AbstractDict, outfilename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:268
  • Mads.createproblem(param::AbstractVector, obs::AbstractVecOrMat, f::Union{AbstractString, Function, Symbol}; problemname, paramkey, paramname, paramplotname, paramtype, parammin, parammax, paramminorig, parammaxorig, paramdist, distribution, expressions, paramlog, obskey, obsweight, obstime, obsmin, obsmax, obsminorig, obsmaxorig, obsdist) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:227
  • Mads.createproblem(paramfile::AbstractString, obsfile::AbstractString, f::Union{AbstractString, Function}; kw...) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:211

Arguments:

  • f::Union{AbstractString, Function, Symbol}
  • f::Union{AbstractString, Function}
  • in::Integer
  • infilename::AbstractString : input Mads file
  • madsdata::AbstractDict : MADS problem dictionary
  • obs::AbstractVecOrMat
  • obsfile::AbstractString
  • out::Integer
  • outfilename::AbstractString : output Mads file
  • param::AbstractVector
  • paramfile::AbstractString
  • predictions::AbstractDict : dictionary of model predictions

Keywords:

  • distribution
  • expressions
  • obsdist
  • obskey
  • obsmax
  • obsmaxorig
  • obsmin
  • obsminorig
  • obstime
  • obsweight
  • paramdist
  • paramkey
  • paramlog
  • parammax
  • parammaxorig
  • parammin
  • paramminorig
  • paramname
  • paramplotname
  • paramtype
  • problemname

Returns:

  • new MADS problem dictionary
source
Mads.createtempdirMethod

Create temporary directory

Methods:

  • Mads.createtempdir(tempdirname::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1449

Arguments:

  • tempdirname::AbstractString : temporary directory name
source
Mads.deleteNaN!Method

Delete rows with NaN in a dataframe df

Methods:

  • Mads.deleteNaN!(df::DataFrames.DataFrame) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:1093

Arguments:

  • df::DataFrames.DataFrame : dataframe
source
Mads.deletekeyword!Function

Delete a keyword in a class within the Mads dictionary madsdata

Methods:

  • Mads.deletekeyword!(madsdata::AbstractDict, class::AbstractString, keyword::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:343
  • Mads.deletekeyword!(madsdata::AbstractDict, keyword::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:337

Arguments:

  • class::AbstractString : dictionary class; if not provided searches for keyword in Problem class
  • keyword::AbstractString : dictionary key
  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.deleteoffwells!Method

Delete all wells marked as being off in the MADS problem dictionary

Methods:

  • Mads.welloff!(madsdata::AbstractDict, wellname::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:632

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • wellname::AbstractString : name of the well to be turned off
source
Mads.deletetimes!Method

Delete all times in the MADS problem dictionary in a given list.

Methods:

  • Mads.welloff!(madsdata::AbstractDict, wellname::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:632

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • wellname::AbstractString : name of the well to be turned off
source
Mads.dependentsFunction

Lists module dependents on a module (Mads by default)

Methods:

  • Mads.dependents() : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:71
  • Mads.dependents(modulename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:71
  • Mads.dependents(modulename::AbstractString, filter::Bool) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:71

Arguments:

  • filter::Bool : whether to filter modules [default=false]
  • modulename::AbstractString : module name [default="Mads"]

Returns:

  • modules that are dependents of the input module
source
Mads.diffFunction

Diff the latest version of Mads modules in the repository

Methods:

  • Mads.diff() : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:198
  • Mads.diff(modulename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:198

Arguments:

  • modulename::AbstractString : module name
source
Mads.documentation_createFunction

Create web documentation

Methods:

  • Mads.documentation_create() : /home/travis/build/madsjulia/Mads.jl/src/MadsPublish.jl:9
  • Mads.documentation_create(modules_doc) : /home/travis/build/madsjulia/Mads.jl/src/MadsPublish.jl:9
  • Mads.documentation_create(modules_doc, modules_load) : /home/travis/build/madsjulia/Mads.jl/src/MadsPublish.jl:9

Arguments:

  • modules_doc
  • modules_load
source
Mads.documentation_deployMethod

Create web documentation

Methods:

  • Mads.documentation_deploy(; deploy_config) : /home/travis/build/madsjulia/Mads.jl/src/MadsPublish.jl:40

Keywords:

  • deploy_config
source
Mads.dumpasciifileMethod

Dump ASCII file

Methods:

  • Mads.dumpasciifile(filename::AbstractString, data) : /home/travis/build/madsjulia/Mads.jl/src/MadsASCII.jl:29

Arguments:

  • data : data to dump
  • filename::AbstractString : ASCII file name

Dumps:

  • ASCII file with the name in "filename"
source
Mads.dumpjsonfileMethod

Dump a JSON file

Methods:

  • Mads.dumpjsonfile(filename::AbstractString, data) : /home/travis/build/madsjulia/Mads.jl/src/MadsJSON.jl:38

Arguments:

  • data : data to dump
  • filename::AbstractString : JSON file name

Dumps:

  • JSON file with the name in "filename"
source
Mads.dumpwelldataMethod

Dump well data from MADS problem dictionary into a ASCII file

Methods:

  • Mads.dumpwelldata(madsdata::AbstractDict, filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1315

Arguments:

  • filename::AbstractString : output file name
  • madsdata::AbstractDict : MADS problem dictionary

Dumps:

  • filename : a ASCII file
source
Mads.dumpyamlfileMethod

Dump YAML file

Methods:

  • Mads.dumpyamlfile(filename::AbstractString, data) : /home/travis/build/madsjulia/Mads.jl/src/MadsYAML.jl:29

Arguments:

  • data : YAML data
  • filename::AbstractString : output file name
source
Mads.dumpyamlmadsfileMethod

Dump YAML Mads file

Methods:

  • Mads.dumpyamlmadsfile(madsdata::AbstractDict, filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsYAML.jl:41

Arguments:

  • filename::AbstractString : output file name
  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.efastMethod

Sensitivity analysis using Saltelli's extended Fourier Amplitude Sensitivity Testing (eFAST) method

Methods:

  • Mads.efast(md::AbstractDict; N, M, gamma, seed, checkpointfrequency, save, load, restartdir, restart, rng) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:1136

Arguments:

  • md::AbstractDict : MADS problem dictionary

Keywords:

  • M : maximum number of harmonics [default=6]
  • N : number of samples [default=100]
  • checkpointfrequency : check point frequency [default=N]
  • gamma : multiplication factor (Saltelli 1999 recommends gamma = 2 or 4) [default=4]
  • load
  • restart : save restart information [default=false]
  • restartdir : directory where files will be stored containing model results for the efast simulation restarts [default="efastcheckpoints"]
  • rng
  • save
  • seed : random seed [default=0]
source
Mads.emceesamplingFunction

Bayesian sampling with Goodman & Weare's Affine Invariant Markov chain Monte Carlo (MCMC) Ensemble sampler (aka Emcee)

Methods:

  • Mads.emceesampling(madsdata::AbstractDict, p0::Array; numwalkers, nsteps, burnin, thinning, seed, weightfactor, rng, distributed_function) : /home/travis/build/madsjulia/Mads.jl/src/MadsMonteCarlo.jl:47
  • Mads.emceesampling(madsdata::AbstractDict; numwalkers, sigma, seed, rng, kw...) : /home/travis/build/madsjulia/Mads.jl/src/MadsMonteCarlo.jl:24

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • p0::Array : initial parameters (matrix of size (number of parameters, number of walkers) or (length(Mads.getoptparamkeys(madsdata)), numwalkers))

Keywords:

  • burnin : number of initial realizations before the MCMC are recorded [default=10]
  • distributed_function
  • nsteps : number of final realizations in the chain [default=100]
  • numwalkers : number of walkers (if in parallel this can be the number of available processors; in general, the higher the number of walkers, the better the results and computational time [default=10]
  • rng
  • seed : random seed [default=0]
  • sigma : a standard deviation parameter used to initialize the walkers [default=0.01]
  • thinning : removal of any thinning realization [default=1]
  • weightfactor : weight factor [default=1.0]

Returns:

  • MCMC chain
  • log likelihoods of the final samples in the chain

Examples:

Mads.emceesampling(madsdata; numwalkers=10, nsteps=100, burnin=100, thinning=1, seed=2016, sigma=0.01)
Mads.emceesampling(madsdata, p0; numwalkers=10, nsteps=100, burnin=10, thinning=1, seed=2016)
source
Mads.estimationerrorFunction

Estimate kriging error

Methods:

  • Mads.estimationerror(w::AbstractVector, covmat::AbstractMatrix, covvec::AbstractVector, cov0::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsKriging.jl:205
  • Mads.estimationerror(w::AbstractVector, x0::AbstractVector, X::AbstractMatrix, covfn::Function) : /home/travis/build/madsjulia/Mads.jl/src/MadsKriging.jl:198

Arguments:

  • X::AbstractMatrix : observation matrix
  • cov0::Number : zero-separation covariance
  • covfn::Function
  • covmat::AbstractMatrix : covariance matrix
  • covvec::AbstractVector : covariance vector
  • w::AbstractVector : kriging weights
  • x0::AbstractVector : estimated locations

Returns:

  • estimation kriging error
source
Mads.evaluatemadsexpressionMethod

Evaluate an expression string based on a parameter dictionary

Methods:

  • Mads.evaluatemadsexpression(expressionstring::AbstractString, parameters::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsMisc.jl:154

Arguments:

  • expressionstring::AbstractString : expression string
  • parameters::AbstractDict : parameter dictionary applied to evaluate the expression string

Returns:

  • dictionary containing the expression names as keys, and the values of the expression as values
source
Mads.evaluatemadsexpressionsFunction

Evaluate all the expressions in the Mads problem dictiorany based on a parameter dictionary

Methods:

  • Mads.evaluatemadsexpressions(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsMisc.jl:173
  • Mads.evaluatemadsexpressions(madsdata::AbstractDict, parameters::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsMisc.jl:173

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • parameters::AbstractDict : parameter dictionary applied to evaluate the expression strings

Returns:

  • dictionary containing the parameter and expression names as keys, and the values of the expression as values
source
Mads.exampleMethod

List available examples

Methods:

  • Mads.examples() : /home/travis/build/madsjulia/Mads.jl/src/MadsExamples.jl:6
source
Mads.examplesMethod

List available examples

Methods:

  • Mads.examples() : /home/travis/build/madsjulia/Mads.jl/src/MadsExamples.jl:6
source
Mads.expcovMethod

Exponential spatial covariance function

Methods:

  • Mads.expcov(h::Number, maxcov::Number, scale::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsKriging.jl:31

Arguments:

  • h::Number : separation distance
  • maxcov::Number : maximum covariance
  • scale::Number : scale

Returns:

  • covariance
source
Mads.exponentialvariogramMethod

Exponential variogram

Methods:

  • Mads.exponentialvariogram(h::Number, sill::Number, range::Number, nugget::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsKriging.jl:83

Arguments:

  • h::Number : separation distance
  • nugget::Number : nugget
  • range::Number : range
  • sill::Number : sill

Returns:

  • Exponential variogram
source
Mads.filterkeysFunction

Filter dictionary keys based on a string or regular expression

Methods:

  • Mads.filterkeys(dict::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:979
  • Mads.filterkeys(dict::AbstractDict, key::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:979
  • Mads.filterkeys(dict::AbstractDict, key::Regex) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:978

Arguments:

  • dict::AbstractDict : dictionary
  • key::AbstractString : the regular expression or string used to filter dictionary keys
  • key::Regex : the regular expression or string used to filter dictionary keys
source
Mads.forwardFunction

Perform a forward run using the initial or provided values for the model parameters

Methods:

  • Mads.forward(madsdata::AbstractDict, paramarray::AbstractArray; all, checkpointfrequency, checkpointfilename) : /home/travis/build/madsjulia/Mads.jl/src/MadsForward.jl:46
  • Mads.forward(madsdata::AbstractDict, paramdict::AbstractDict; all, checkpointfrequency, checkpointfilename) : /home/travis/build/madsjulia/Mads.jl/src/MadsForward.jl:11
  • Mads.forward(madsdata::AbstractDict; all) : /home/travis/build/madsjulia/Mads.jl/src/MadsForward.jl:7

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • paramarray::AbstractArray : array of model parameter values
  • paramdict::AbstractDict : dictionary of model parameter values

Keywords:

  • all : all model results are returned [default=false]
  • checkpointfilename : check point file name [default="checkpoint_forward"]
  • checkpointfrequency : check point frequency for storing restart information [default=0]

Returns:

  • dictionary of model predictions
source
Mads.forwardgridFunction

Perform a forward run over a 3D grid defined in madsdata using the initial or provided values for the model parameters

Methods:

  • Mads.forwardgrid(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsForward.jl:134
  • Mads.forwardgrid(madsdatain::AbstractDict, paramvalues::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsForward.jl:139

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • madsdatain::AbstractDict : MADS problem dictionary
  • paramvalues::AbstractDict : dictionary of model parameter values

Returns:

  • 3D array with model predictions along a 3D grid
source
Mads.freeFunction

Free Mads modules

Methods:

  • Mads.free() : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:231
  • Mads.free(modulename::AbstractString; required, all) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:231

Arguments:

  • modulename::AbstractString : module name

Keywords:

  • all : free all the modules [default=false]
  • required : only free Mads.required modules [default=false]
source
Mads.functionsFunction

List available functions in the MADS modules:

Methods:

  • Mads.functions() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelp.jl:57
  • Mads.functions(m::Union{Module, Symbol}) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelp.jl:96
  • Mads.functions(m::Union{Module, Symbol}, re::Regex; shortoutput, quiet) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelp.jl:66
  • Mads.functions(m::Union{Module, Symbol}, string::AbstractString; shortoutput, quiet) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelp.jl:96
  • Mads.functions(re::Regex; shortoutput, quiet) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelp.jl:48
  • Mads.functions(string::AbstractString; shortoutput, quiet) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelp.jl:57

Arguments:

  • m::Union{Module, Symbol} : MADS module
  • re::Regex
  • string::AbstractString : string to display functions with matching names

Keywords:

  • quiet
  • shortoutput

Examples:

Mads.functions()
Mads.functions(BIGUQ)
Mads.functions("get")
Mads.functions(Mads, "get")
source
Mads.gaussiancovMethod

Gaussian spatial covariance function

Methods:

  • Mads.gaussiancov(h::Number, maxcov::Number, scale::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsKriging.jl:17

Arguments:

  • h::Number : separation distance
  • maxcov::Number : maximum covariance
  • scale::Number : scale

Returns:

  • covariance
source
Mads.gaussianvariogramMethod

Gaussian variogram

Methods:

  • Mads.gaussianvariogram(h::Number, sill::Number, range::Number, nugget::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsKriging.jl:104

Arguments:

  • h::Number : separation distance
  • nugget::Number : nugget
  • range::Number : range
  • sill::Number : sill

Returns:

  • Gaussian variogram
source
Mads.getcovmatMethod

Get spatial covariance matrix

Methods:

  • Mads.getcovmat(X::AbstractMatrix, covfunction::Function) : /home/travis/build/madsjulia/Mads.jl/src/MadsKriging.jl:160

Arguments:

  • X::AbstractMatrix : matrix with coordinates of the data points (x or y)
  • covfunction::Function

Returns:

  • spatial covariance matrix
source
Mads.getcovvec!Method

Get spatial covariance vector

Methods:

  • Mads.getcovvec!(covvec::AbstractVector, x0::AbstractVector, X::AbstractMatrix, covfn::Function) : /home/travis/build/madsjulia/Mads.jl/src/MadsKriging.jl:186

Arguments:

  • X::AbstractMatrix : matrix with coordinates of the data points
  • covfn::Function : spatial covariance function
  • covvec::AbstractVector : spatial covariance vector
  • x0::AbstractVector : vector with coordinates of the estimation points (x or y)

Returns:

  • spatial covariance vector
source
Mads.getdictvaluesFunction

Get dictionary values for keys based on a string or regular expression

Methods:

  • Mads.getdictvalues(dict::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1001
  • Mads.getdictvalues(dict::AbstractDict, key::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1001
  • Mads.getdictvalues(dict::AbstractDict, key::Regex) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1000

Arguments:

  • dict::AbstractDict : dictionary
  • key::AbstractString : the key to find value for
  • key::Regex : the key to find value for
source
Mads.getdirMethod

Get directory

Methods:

  • Mads.getdir(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:570

Arguments:

  • filename::AbstractString : file name

Returns:

  • directory in file name

Example:

d = Mads.getdir("a.mads") # d = "."
d = Mads.getdir("test/a.mads") # d = "test"
source
Mads.getdistributionMethod

Parse parameter distribution from a string

Methods:

  • Mads.getdistribution(dist::AbstractString, i::AbstractString, inputtype::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsMisc.jl:207

Arguments:

  • dist::AbstractString : parameter distribution
  • i::AbstractString
  • inputtype::AbstractString : input type (parameter or observation)

Returns:

  • distribution
source
Mads.getextensionMethod

Get file name extension

Methods:

  • Mads.getextension(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:746

Arguments:

  • filename::AbstractString : file name

Returns:

  • file name extension

Example:

ext = Mads.getextension("a.mads") # ext = "mads"
source
Mads.getfilenamesMethod

Get file names by expanding wildcards

Methods:

  • Mads.getfilenames(cmdstring::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:103

Arguments:

  • cmdstring::AbstractString
source
Mads.getimportantsamplesMethod

Get important samples

Methods:

  • Mads.getimportantsamples(samples::Array, llhoods::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:357

Arguments:

  • llhoods::AbstractVector : vector of log-likelihoods
  • samples::Array : array of samples

Returns:

  • array of important samples
source
Mads.getmadsinputfileMethod

Get the default MADS input file set as a MADS global variable using setmadsinputfile(filename)

Methods:

  • Mads.getmadsinputfile() : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:522

Returns:

  • input file name (e.g. input_file_name.mads)
source
Mads.getmadsproblemdirMethod

Get the directory where the Mads data file is located

Methods:

  • Mads.getmadsproblemdir(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:593

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Example:

madsdata = Mads.loadmadsfile("../../a.mads")
madsproblemdir = Mads.getmadsproblemdir(madsdata)

where madsproblemdir = "../../"

source
Mads.getmadsrootnameMethod

Get the MADS problem root name

Methods:

  • Mads.getmadsrootname(madsdata::AbstractDict; first, version) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:544

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • first : use the first . in filename as the seperator between root name and extention [default=true]
  • version : delete version information from filename for the returned rootname [default=false]

Example:

madsrootname = Mads.getmadsrootname(madsdata)

Returns:

  • root of file name
source
Mads.getnextmadsfilenameMethod

Get next mads file name

Methods:

  • Mads.getnextmadsfilename(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:709

Arguments:

  • filename::AbstractString : file name

Returns:

  • next mads file name
source
Mads.getobsdistMethod

Get an array with dist values for observations in the MADS problem dictionary defined by obskeys

source
Mads.getobsdistMethod

Get an array with dist values for all observations in the MADS problem dictionary

source
Mads.getobskeysMethod

Get keys for all observations in the MADS problem dictionary

Methods:

  • Mads.getobskeys(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:43

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • keys for all observations in the MADS problem dictionary
source
Mads.getobslogMethod

Get an array with log values for observations in the MADS problem dictionary defined by obskeys

source
Mads.getobslogMethod

Get an array with log values for all observations in the MADS problem dictionary

source
Mads.getobsmaxMethod

Get an array with max values for observations in the MADS problem dictionary defined by obskeys

source
Mads.getobsmaxMethod

Get an array with max values for all observations in the MADS problem dictionary

source
Mads.getobsminMethod

Get an array with min values for observations in the MADS problem dictionary defined by obskeys

source
Mads.getobsminMethod

Get an array with min values for all observations in the MADS problem dictionary

source
Mads.getobstargetMethod

Get an array with target values for observations in the MADS problem dictionary defined by obskeys

source
Mads.getobstargetMethod

Get an array with target values for all observations in the MADS problem dictionary

source
Mads.getobstimeMethod

Get an array with time values for observations in the MADS problem dictionary defined by obskeys

source
Mads.getobstimeMethod

Get an array with time values for all observations in the MADS problem dictionary

source
Mads.getobsweightMethod

Get an array with weight values for observations in the MADS problem dictionary defined by obskeys

source
Mads.getobsweightMethod

Get an array with weight values for all observations in the MADS problem dictionary

source
Mads.getoptparamsFunction

Get optimizable parameters

Methods:

  • Mads.getoptparams(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:364
  • Mads.getoptparams(madsdata::AbstractDict, parameterarray::Array) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:364
  • Mads.getoptparams(madsdata::AbstractDict, parameterarray::Array, optparameterkey::Array) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:364

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • optparameterkey::Array : optimizable parameter keys
  • parameterarray::Array : parameter array

Returns:

  • parameter array
source
Mads.getparamdictMethod

Get dictionary with all parameters and their respective initial values

Methods:

  • Mads.getparamdict(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:61

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • dictionary with all parameters and their respective initial values
source
Mads.getparamdistributionsMethod

Get probabilistic distributions of all parameters in the MADS problem dictionary

Note:

Probabilistic distribution of parameters can be defined only if dist or min/max model parameter fields are specified in the MADS problem dictionary madsdata.

Methods:

  • Mads.getparamdistributions(madsdata::AbstractDict; init_dist) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:696

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • init_dist : if true use the distribution defined for initialization in the MADS problem dictionary (defined using init_dist parameter field); else use the regular distribution defined in the MADS problem dictionary (defined using dist parameter field [default=false]

Returns:

  • probabilistic distributions
source
Mads.getparamkeysMethod

Get keys of all parameters in the MADS problem dictionary

Methods:

  • Mads.getparamkeys(madsdata::AbstractDict; filter) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:42

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • filter : parameter filter

Returns:

  • array with the keys of all parameters in the MADS problem dictionary
source
Mads.getparamrandomFunction

Get independent sampling of model parameters defined in the MADS problem dictionary

Methods:

  • Mads.getparamrandom(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:393
  • Mads.getparamrandom(madsdata::AbstractDict, numsamples::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:393
  • Mads.getparamrandom(madsdata::AbstractDict, numsamples::Integer, parameterkey::AbstractString; init_dist) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:393
  • Mads.getparamrandom(madsdata::AbstractDict, parameterkey::AbstractString; numsamples, paramdist, init_dist) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:410

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • numsamples::Integer : number of samples, [default=1]
  • parameterkey::AbstractString : model parameter key

Keywords:

  • init_dist : if true use the distribution set for initialization in the MADS problem dictionary (defined using init_dist parameter field); if false (default) use the regular distribution set in the MADS problem dictionary (defined using dist parameter field)
  • numsamples : number of samples
  • paramdist : dictionary of parameter distributions

Returns:

  • generated sample
source
Mads.getparamsinit_maxFunction

Get an array with init_max values for parameters defined by paramkeys

Methods:

  • Mads.getparamsinit_max(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:275
  • Mads.getparamsinit_max(madsdata::AbstractDict, paramkeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:275

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • paramkeys::AbstractVector : parameter keys

Returns:

  • the parameter values
source
Mads.getparamsinit_minFunction

Get an array with init_min values for parameters

Methods:

  • Mads.getparamsinit_min(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:229
  • Mads.getparamsinit_min(madsdata::AbstractDict, paramkeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:229

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • paramkeys::AbstractVector : parameter keys

Returns:

  • the parameter values
source
Mads.getparamsmaxFunction

Get an array with max values for parameters defined by paramkeys

Methods:

  • Mads.getparamsmax(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:195
  • Mads.getparamsmax(madsdata::AbstractDict, paramkeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:195

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • paramkeys::AbstractVector : parameter keys

Returns:

  • returns the parameter values
source
Mads.getparamsminFunction

Get an array with min values for parameters defined by paramkeys

Methods:

  • Mads.getparamsmin(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:161
  • Mads.getparamsmin(madsdata::AbstractDict, paramkeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:161

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • paramkeys::AbstractVector : parameter keys

Returns:

  • the parameter values
source
Mads.getproblemdirMethod

Get the directory where currently Mads is running

Methods:

  • Mads.getproblemdir() : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:616

Example:

problemdir = Mads.getproblemdir()

Returns:

  • Mads problem directory
source
Mads.getprocsMethod

Get the number of processors

Methods:

  • Mads.getprocs() : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:27
source
Mads.getrestartMethod

Get MADS restart status

Methods:

  • Mads.getrestart(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:94

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.getrestartdirFunction

Get the directory where Mads restarts will be stored

Methods:

  • Mads.getrestartdir(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsFunc.jl:387
  • Mads.getrestartdir(madsdata::AbstractDict, suffix::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsFunc.jl:387

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • suffix::AbstractString : Suffix to be added to the name of restart directory

Returns:

  • restart directory where reusable model results will be stored
source
Mads.getrootnameMethod

Get file name root

Methods:

  • Mads.getrootname(filename::AbstractString; first, version) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:646

Arguments:

  • filename::AbstractString : file name

Keywords:

  • first : use the first . in filename as the seperator between root name and extention [default=true]
  • version : delete version information from filename for the returned rootname [default=false]

Returns:

  • root of file name

Example:

r = Mads.getrootname("a.rnd.dat") # r = "a"
r = Mads.getrootname("a.rnd.dat", first=false) # r = "a.rnd"
source
Mads.getseedMethod

Get and return current random seed.

Methods:

  • Mads.getseed() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:496
source
Mads.getsindxMethod

Get sin-space dx

Methods:

  • Mads.getsindx(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:375

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • sin-space dx value
source
Mads.getsourcekeysMethod

Get keys of all source parameters in the MADS problem dictionary

Methods:

  • Mads.getsourcekeys(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:79

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • array with keys of all source parameters in the MADS problem dictionary
source
Mads.gettargetMethod

Get observation target

Methods:

  • Mads.gettarget(o::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:221

Arguments:

  • o::AbstractDict : observation data

Returns:

  • observation target
source
Mads.gettargetkeysMethod

Get keys for all targets (observations with weights greater than zero) in the MADS problem dictionary

Methods:

  • Mads.gettargetkeys(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:57

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • keys for all targets in the MADS problem dictionary
source
Mads.gettimeMethod

Get observation time

Methods:

  • Mads.gettime(o::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:144

Arguments:

  • o::AbstractDict : observation data

Returns:

  • observation time ("NaN" it time is missing)
source
Mads.getweightMethod

Get observation weight

Methods:

  • Mads.getweight(o::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:182

Arguments:

  • o::AbstractDict : observation data

Returns:

  • observation weight ("NaN" when weight is missing)
source
Mads.getwelldataMethod

Get spatial and temporal data in the Wells class

Methods:

  • Mads.getwelldata(madsdata::AbstractDict; time) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:727

Arguments:

  • madsdata::AbstractDict : Mads problem dictionary

Keywords:

  • time : get observation times [default=false]

Returns:

  • array with spatial and temporal data in the Wells class
source
Mads.getwellkeysMethod

Get keys for all wells in the MADS problem dictionary

Methods:

  • Mads.getwellkeys(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:74

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • keys for all wells in the MADS problem dictionary
source
Mads.getwelltargetsMethod

Methods:

  • Mads.getwelltargets(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:761

Arguments:

  • madsdata::AbstractDict : Mads problem dictionary

Returns:

  • array with targets in the Wells class
source
Mads.graphoffMethod

MADS graph output off

Methods:

  • Mads.graphoff() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:166
source
Mads.graphonMethod

MADS graph output on

Methods:

  • Mads.graphon() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:157
source
Mads.haskeywordFunction

Check for a keyword in a class within the Mads dictionary madsdata

Methods:

  • Mads.haskeyword(madsdata::AbstractDict, class::AbstractString, keyword::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:275
  • Mads.haskeyword(madsdata::AbstractDict, keyword::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:272

Arguments:

  • class::AbstractString : dictionary class; if not provided searches for keyword in Problem class
  • keyword::AbstractString : dictionary key
  • madsdata::AbstractDict : MADS problem dictionary

Returns: true or false

Examples:

- `Mads.haskeyword(madsdata, "disp")` ... searches in `Problem` class by default
- `Mads.haskeyword(madsdata, "Wells", "R-28")` ... searches in `Wells` class for a keyword "R-28"
source
Mads.helpMethod

Produce MADS help information

Methods:

  • Mads.help() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelp.jl:35
source
Mads.importeverywhereMethod

Import Julia function everywhere from a file. The first function in the Julia input file is the one that will be targeted by Mads for execution.

Methods:

  • Mads.importeverywhere(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsFunc.jl:439

Arguments:

  • filename::AbstractString : file name

Returns:

  • Julia function to execute the model
source
Mads.indexkeysFunction

Find indexes for dictionary keys based on a string or regular expression

Methods:

  • Mads.indexkeys(dict::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:990
  • Mads.indexkeys(dict::AbstractDict, key::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:990
  • Mads.indexkeys(dict::AbstractDict, key::Regex) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:989

Arguments:

  • dict::AbstractDict : dictionary
  • key::AbstractString : the key to find index for
  • key::Regex : the key to find index for
source
Mads.infogap_jumpFunction

Information Gap Decision Analysis using JuMP

Methods:

  • Mads.infogap_jump() : /home/travis/build/madsjulia/Mads.jl/src/MadsInfoGap.jl:23
  • Mads.infogap_jump(madsdata::AbstractDict; horizons, retries, random, maxiter, verbosity, seed) : /home/travis/build/madsjulia/Mads.jl/src/MadsInfoGap.jl:23

Arguments:

  • madsdata::AbstractDict : Mads problem dictionary

Keywords:

  • horizons : info-gap horizons of uncertainty [default=[0.05, 0.1, 0.2, 0.5]]
  • maxiter : maximum number of iterations [default=3000]
  • random : random initial guesses [default=false]
  • retries : number of solution retries [default=1]
  • seed : random seed [default=0]
  • verbosity : verbosity output level [default=0]
source
Mads.infogap_jump_polynomialFunction

Information Gap Decision Analysis using JuMP

Methods:

  • Mads.infogap_jump_polynomial() : /home/travis/build/madsjulia/Mads.jl/src/MadsInfoGap.jl:128
  • Mads.infogap_jump_polynomial(madsdata::AbstractDict; horizons, retries, random, maxiter, verbosity, quiet, plot, model, seed) : /home/travis/build/madsjulia/Mads.jl/src/MadsInfoGap.jl:128

Arguments:

  • madsdata::AbstractDict : Mads problem dictionary

Keywords:

  • horizons : info-gap horizons of uncertainty [default=[0.05, 0.1, 0.2, 0.5]]
  • maxiter : maximum number of iterations [default=3000]
  • model : model id [default=1]
  • plot : activate plotting [default=false]
  • quiet : quiet [default=false]
  • random : random initial guesses [default=false]
  • retries : number of solution retries [default=1]
  • seed : random seed [default=0]
  • verbosity : verbosity output level [default=0]

Returns:

  • hmin, hmax
source
Mads.infogap_moi_linFunction

Information Gap Decision Analysis using MathOptInterface

Methods:

  • Mads.infogap_moi_lin() : /home/travis/build/madsjulia/Mads.jl/src/MadsInfoGap.jl:442
  • Mads.infogap_moi_lin(madsdata::AbstractDict; horizons, retries, random, maxiter, verbosity, seed, pinit) : /home/travis/build/madsjulia/Mads.jl/src/MadsInfoGap.jl:442

Arguments:

  • madsdata::AbstractDict : Mads problem dictionary

Keywords:

  • horizons : info-gap horizons of uncertainty [default=[0.05, 0.1, 0.2, 0.5]]
  • maxiter : maximum number of iterations [default=3000]
  • pinit : vector with initial parameters
  • random : random initial guesses [default=false]
  • retries : number of solution retries [default=1]
  • seed : random seed [default=0]
  • verbosity : verbosity output level [default=0]
source
Mads.infogap_moi_polynomialFunction

Information Gap Decision Analysis using MathOptInterface

Methods:

  • Mads.infogap_moi_polynomial() : /home/travis/build/madsjulia/Mads.jl/src/MadsInfoGap.jl:301
  • Mads.infogap_moi_polynomial(madsdata::AbstractDict; horizons, retries, random, maxiter, verbosity, seed, rng, pinit) : /home/travis/build/madsjulia/Mads.jl/src/MadsInfoGap.jl:301

Arguments:

  • madsdata::AbstractDict : Mads problem dictionary

Keywords:

  • horizons : info-gap horizons of uncertainty [default=[0.05, 0.1, 0.2, 0.5]]
  • maxiter : maximum number of iterations [default=3000]
  • pinit : vector with initial parameters
  • random : random initial guesses [default=false]
  • retries : number of solution retries [default=1]
  • rng
  • seed : random seed [default=0]
  • verbosity : verbosity output level [default=0]
source
Mads.ins_obsMethod

Apply Mads instruction file instructionfilename to read model output file modeloutputfilename

Methods:

  • Mads.ins_obs(instructionfilename::AbstractString, modeloutputfilename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1208

Arguments:

  • instructionfilename::AbstractString : instruction file name
  • modeloutputfilename::AbstractString : model output file name

Returns:

  • obsdict : observation dictionary with the model outputs
source
Mads.instline2regexsMethod

Convert an instruction line in the Mads instruction file into regular expressions

Methods:

  • Mads.instline2regexs(instline::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1108

Arguments:

  • instline::AbstractString : instruction line

Returns:

  • regexs : regular expressions
  • obsnames : observation names
  • getparamhere : parameters
source
Mads.invobsweights!Function

Set inversely proportional observation weights in the MADS problem dictionary

Methods:

  • Mads.invobsweights!(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:327
  • Mads.invobsweights!(madsdata::AbstractDict, multiplier::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:327
  • Mads.invobsweights!(madsdata::AbstractDict, multiplier::Number, obskeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:327

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • multiplier::Number : weight multiplier
  • obskeys::AbstractVector
source
Mads.invwellweights!Function

Set inversely proportional well weights in the MADS problem dictionary

Methods:

  • Mads.invwellweights!(madsdata::AbstractDict, multiplier::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:379
  • Mads.invwellweights!(madsdata::AbstractDict, multiplier::Number, wellkeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:379

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • multiplier::Number : weight multiplier
  • wellkeys::AbstractVector
source
Mads.islogMethod

Is parameter with key parameterkey log-transformed?

Methods:

  • Mads.islog(madsdata::AbstractDict, parameterkey::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:437

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • parameterkey::AbstractString : parameter key

Returns:

  • true if log-transformed, false otherwise
source
Mads.isobsMethod

Is a dictionary containing all the observations

Methods:

  • Mads.isobs(madsdata::AbstractDict, dict::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:17

Arguments:

  • dict::AbstractDict : dictionary
  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • true if the dictionary contain all the observations, false otherwise
source
Mads.isoptMethod

Is parameter with key parameterkey optimizable?

Methods:

  • Mads.isopt(madsdata::AbstractDict, parameterkey::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:417

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • parameterkey::AbstractString : parameter key

Returns:

  • true if optimizable, false if not
source
Mads.isparamMethod

Check if a dictionary containing all the Mads model parameters

Methods:

  • Mads.isparam(madsdata::AbstractDict, dict::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:15

Arguments:

  • dict::AbstractDict : dictionary
  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • true if the dictionary containing all the parameters, false otherwise
source
Mads.ispkgavailableMethod

Checks if package is available

Methods:

  • Mads.ispkgavailable(modulename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:591

Arguments:

  • modulename::AbstractString : module name

Returns:

  • true or false
source
Mads.ispkgavailable_oldMethod

Checks if package is available

Methods:

  • Mads.ispkgavailable_old(modulename::AbstractString; quiet) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:569

Arguments:

  • modulename::AbstractString : module name

Keywords:

  • quiet

Returns:

  • true or false
source
Mads.krigeMethod

Kriging

Methods:

  • Mads.krige(x0mat::AbstractMatrix, X::AbstractMatrix, Z::AbstractVector, covfn::Function) : /home/travis/build/madsjulia/Mads.jl/src/MadsKriging.jl:125

Arguments:

  • X::AbstractMatrix : coordinates of the observation (conditioning) data
  • Z::AbstractVector : values for the observation (conditioning) data
  • covfn::Function : spatial covariance function
  • x0mat::AbstractMatrix : point coordinates at which to obtain kriging estimates

Returns:

  • kriging estimates at x0mat
source
Mads.levenberg_marquardtFunction

Levenberg-Marquardt optimization

Methods:

  • Mads.levenberg_marquardt(f::Function, g::Function, x0) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:357
  • Mads.levenberg_marquardt(f::Function, g::Function, x0, o::Function; root, tolX, tolG, tolOF, tolOFcount, minOF, maxEval, maxIter, maxJacobians, lambda, lambda_scale, lambda_mu, lambda_nu, np_lambda, show_trace, quiet, callbackinitial, callbackiteration, callbackjacobian, callbackfinal, parallel_execution, center_provided) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:357

Arguments:

  • f::Function : forward model function
  • g::Function : gradient function for the forward model
  • o::Function : objective function [default=x->(x'*x)[1]]
  • x0 : initial parameter guess

Keywords:

  • callbackfinal : final call back function [default=(best_x::AbstractVector, of::Number, lambda::Number)->nothing]
  • callbackinitial
  • callbackiteration : call back function for each iteration [default=(best_x::AbstractVector, of::Number, lambda::Number)->nothing]
  • callbackjacobian : call back function for each Jacobian [default=(x::AbstractVector, J::AbstractMatrix)->nothing]
  • center_provided
  • lambda : initial Levenberg-Marquardt lambda [default=eps(Float32)]
  • lambda_mu : lambda multiplication factor μ [default=10]
  • lambda_nu : lambda multiplication factor ν [default=2]
  • lambda_scale : lambda scaling factor [default=1e-3,]
  • maxEval : maximum number of model evaluations [default=1001]
  • maxIter : maximum number of optimization iterations [default=100]
  • maxJacobians : maximum number of Jacobian solves [default=100]
  • minOF : objective function update tolerance [default=1e-3]
  • np_lambda : number of parallel lambda solves [default=10]
  • parallel_execution
  • quiet
  • root : Mads problem root name
  • show_trace : shows solution trace [default=false]
  • tolG : parameter space update tolerance [default=1e-6]
  • tolOF : objective function update tolerance [default=1e-3]
  • tolOFcount : number of Jacobian runs with small objective function change [default=5]
  • tolX : parameter space tolerance [default=1e-4]
source
Mads.linktempdirMethod

Link files in a temporary directory

Methods:

  • Mads.linktempdir(madsproblemdir::AbstractString, tempdirname::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1475

Arguments:

  • madsproblemdir::AbstractString : Mads problem directory
  • tempdirname::AbstractString : temporary directory name
source
Mads.loadasciifileMethod

Load ASCII file

Methods:

  • Mads.loadasciifile(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsASCII.jl:14

Arguments:

  • filename::AbstractString : ASCII file name

Returns:

  • data from the file
source
Mads.loadbigyamlfileMethod

Load BIG YAML input file

Methods:

  • Mads.loadmadsfile(filename::AbstractString; bigfile, format, quiet) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:141

Arguments:

  • filename::AbstractString : input file name (e.g. input_file_name.mads)

Keywords:

  • bigfile
  • format
  • quiet

Returns:

  • MADS problem dictionary
source
Mads.loadjsonfileMethod

Load a JSON file

Methods:

  • Mads.loadjsonfile(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsJSON.jl:16

Arguments:

  • filename::AbstractString : JSON file name

Returns:

  • data from the JSON file
source
Mads.loadmadsfileMethod

Load MADS input file defining a MADS problem dictionary

Methods:

  • Mads.loadmadsfile(filename::AbstractString; bigfile, format, quiet) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:141

Arguments:

  • filename::AbstractString : input file name (e.g. input_file_name.mads)

Keywords:

  • bigfile
  • format : acceptable formats are yaml and json [default=yaml]
  • quiet

Returns:

  • MADS problem dictionary

Example:

md = Mads.loadmadsfile("input_file_name.mads")
source
Mads.loadmadsproblemMethod

Load a predefined Mads problem

Methods:

  • Mads.loadmadsproblem(name::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsCreate.jl:14

Arguments:

  • name::AbstractString : predefined MADS problem name

Returns:

  • MADS problem dictionary
source
Mads.loadsaltellirestart!Method

Load Saltelli sensitivity analysis results for fast simulation restarts

Methods:

  • Mads.loadsaltellirestart!(evalmat::Array, matname::AbstractString, restartdir::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:604

Arguments:

  • evalmat::Array : loaded array
  • matname::AbstractString : matrix (array) name (defines the name of the loaded file)
  • restartdir::AbstractString : directory where files will be stored containing model results for fast simulation restarts

Returns:

  • true when successfully loaded, false when it is not
source
Mads.loadyamlfileMethod

Load YAML file

Methods:

  • Mads.loadyamlfile(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsYAML.jl:16

Arguments:

  • filename::AbstractString : file name

Returns:

  • data in the yaml input file
source
Mads.localsaMethod

Local sensitivity analysis based on eigen analysis of the parameter covariance matrix

Methods:

  • Mads.localsa(madsdata::AbstractDict; sinspace, keyword, filename, format, datafiles, imagefiles, par, obs, J) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:124

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • J : Jacobian matrix
  • datafiles : flag to write data files [default=true]
  • filename : output file name
  • format : output plot format (png, pdf, etc.)
  • imagefiles : flag to create image files [default=Mads.graphoutput]
  • keyword : keyword to be added in the filename root
  • obs : observations for the parameter set
  • par : parameter set
  • sinspace : apply sin transformation [default=true]

Dumps:

  • filename : output plot file
source
Mads.long_tests_offMethod

Turn off execution of long MADS tests (default)

Methods:

  • Mads.long_tests_off() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:211
source
Mads.long_tests_onMethod

Turn on execution of long MADS tests

Methods:

  • Mads.long_tests_on() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:202
source
Mads.madsMathOptInterfaceFunction

Define MadsModel type applied for Mads execution using MathOptInterface

Methods:

  • Mads.madsMathOptInterface() : /home/travis/build/madsjulia/Mads.jl/src/MadsMathOptInterface.jl:16
  • Mads.madsMathOptInterface(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsMathOptInterface.jl:16

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary [default=Dict()]
source
Mads.madscoresFunction

Check the number of processors on a series of servers

Methods:

  • Mads.madscores() : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:306
  • Mads.madscores(nodenames::Vector{String}) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:306

Arguments:

  • nodenames::Vector{String} : array with names of machines/nodes [default=madsservers]
source
Mads.madscriticalMethod

MADS critical error messages

Methods:

  • Mads.madscritical(message::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsLog.jl:70

Arguments:

  • message::AbstractString : critical error message
source
Mads.madsdebugFunction

MADS debug messages (controlled by quiet and debuglevel)

Methods:

  • Mads.madsdebug(message::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsLog.jl:23
  • Mads.madsdebug(message::AbstractString, level::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsLog.jl:23

Arguments:

  • level::Int64 : output verbosity level [default=0]
  • message::AbstractString : debug message
source
Mads.madsdirMethod

Change the current directory to the Mads source dictionary

Methods:

  • Mads.madsdir() : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:112
source
Mads.madserrorMethod

MADS error messages

Methods:

  • Mads.madserror(message::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsLog.jl:60

Arguments:

  • message::AbstractString : error message
source
Mads.madsinfoFunction

MADS information/status messages (controlled by quietandverbositylevel`)

Methods:

  • Mads.madsinfo(message::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsLog.jl:38
  • Mads.madsinfo(message::AbstractString, level::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsLog.jl:38

Arguments:

  • level::Int64 : output verbosity level [default=0]
  • message::AbstractString : information/status message
source
Mads.madsloadFunction

Check the load of a series of servers

Methods:

  • Mads.madsload() : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:326
  • Mads.madsload(nodenames::Vector{String}) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:326

Arguments:

  • nodenames::Vector{String} : array with names of machines/nodes [default=madsservers]
source
Mads.madsoutputFunction

MADS output (controlled by quiet and verbositylevel)

Methods:

  • Mads.madsoutput(message::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsLog.jl:8
  • Mads.madsoutput(message::AbstractString, level::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsLog.jl:8

Arguments:

  • level::Int64 : output verbosity level [default=0]
  • message::AbstractString : output message
source
Mads.madsupFunction

Check the uptime of a series of servers

Methods:

  • Mads.madsup() : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:316
  • Mads.madsup(nodenames::Vector{String}) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:316

Arguments:

  • nodenames::Vector{String} : array with names of machines/nodes [default=madsservers]
source
Mads.madswarnMethod

MADS warning messages

Methods:

  • Mads.madswarn(message::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsLog.jl:50

Arguments:

  • message::AbstractString : warning message
source
Mads.makearrayconditionalloglikelihoodMethod

Make a conditional log likelihood function that accepts an array containing the optimal parameter values

Methods:

  • Mads.makearrayconditionalloglikelihood(madsdata::AbstractDict, conditionalloglikelihood) : /home/travis/build/madsjulia/Mads.jl/src/MadsMisc.jl:104

Arguments:

  • conditionalloglikelihood : conditional log likelihood
  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • a conditional log likelihood function that accepts an array
source
Mads.makearrayconditionalloglikelihoodMethod

Make array of conditional log-likelihoods

Methods:

  • Mads.makearrayconditionalloglikelihood(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsBayesInfoGap.jl:158
  • Mads.makearrayconditionalloglikelihood(madsdata::AbstractDict, conditionalloglikelihood) : /home/travis/build/madsjulia/Mads.jl/src/MadsMisc.jl:104

Arguments:

  • conditionalloglikelihood
  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • array of conditional log-likelihoods
source
Mads.makearrayfunctionFunction

Make a version of the function f that accepts an array containing the optimal parameter values

Methods:

  • Mads.makearrayfunction(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsMisc.jl:31
  • Mads.makearrayfunction(madsdata::AbstractDict, f::Function) : /home/travis/build/madsjulia/Mads.jl/src/MadsMisc.jl:31

Arguments:

  • f::Function : function [default=makemadscommandfunction(madsdata)]
  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • function accepting an array containing the optimal parameter values
source
Mads.makearrayloglikelihoodMethod

Make a log likelihood function that accepts an array containing the optimal parameter values

Methods:

  • Mads.makearrayloglikelihood(madsdata::AbstractDict, loglikelihood) : /home/travis/build/madsjulia/Mads.jl/src/MadsMisc.jl:127

Arguments:

  • loglikelihood : log likelihood
  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • a log likelihood function that accepts an array
source
Mads.makebigdt!Method

Setup Bayesian Information Gap Decision Theory (BIG-DT) problem

Methods:

  • Mads.makebigdt!(madsdata::AbstractDict, choice::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsBayesInfoGap.jl:33

Arguments:

  • choice::AbstractDict : dictionary of BIG-DT choices (scenarios)
  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • BIG-DT problem type
source
Mads.makebigdtMethod

Setup Bayesian Information Gap Decision Theory (BIG-DT) problem

Methods:

  • Mads.makebigdt(madsdata::AbstractDict, choice::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsBayesInfoGap.jl:18

Arguments:

  • choice::AbstractDict : dictionary of BIG-DT choices (scenarios)
  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • BIG-DT problem type
source
Mads.makecomputeconcentrationsMethod

Create a function to compute concentrations for all the observation points using Anasol

Methods:

  • Mads.makecomputeconcentrations(madsdata::AbstractDict; calczeroweightobs, calcpredictions) : /home/travis/build/madsjulia/Mads.jl/src/MadsAnasol.jl:177

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • calcpredictions : calculate zero weight predictions [default=true]
  • calczeroweightobs : calculate zero weight observations[default=false]

Returns:

  • function to compute concentrations; the new function returns a dictionary of observations and model predicted concentrations

Examples:

computeconcentrations = Mads.makecomputeconcentrations(madsdata)
paramkeys = Mads.getparamkeys(madsdata)
paramdict = OrderedDict(zip(paramkeys, map(key->madsdata["Parameters"][key]["init"], paramkeys)))
forward_preds = computeconcentrations(paramdict)
source
Mads.makedixonpriceMethod

Make dixon price

Methods:

  • Mads.makedixonprice(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:257

Arguments:

  • n::Integer : number of observations

Returns:

  • dixon price
source
Mads.makedixonprice_gradientMethod

Methods:

  • Mads.makedixonprice(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:257

Arguments:

  • n::Integer : number of observations

Returns:

  • dixon price gradient
source
Mads.makedoublearrayfunctionFunction

Make a version of the function f that accepts an array containing the optimal parameter values, and returns an array of observations

Methods:

  • Mads.makedoublearrayfunction(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsMisc.jl:77
  • Mads.makedoublearrayfunction(madsdata::AbstractDict, f::Function) : /home/travis/build/madsjulia/Mads.jl/src/MadsMisc.jl:77

Arguments:

  • f::Function : function [default=makemadscommandfunction(madsdata)]
  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • function accepting an array containing the optimal parameter values, and returning an array of observations
source
Mads.makelmfunctionsFunction

Make forward model, gradient, objective functions needed for Levenberg-Marquardt optimization

Methods:

  • Mads.makelmfunctions(f::Function) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:107
  • Mads.makelmfunctions(madsdata::AbstractDict; parallel_gradients) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:128

Arguments:

  • f::Function : Function
  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • parallel_gradients

Returns:

  • forward model, gradient, objective functions
source
Mads.makelocalsafunctionMethod

Make gradient function needed for local sensitivity analysis

Methods:

  • Mads.makelocalsafunction(madsdata::AbstractDict; multiplycenterbyweights) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:25

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • multiplycenterbyweights : multiply center by observation weights [default=true]

Returns:

  • gradient function
source
Mads.makelogpriorMethod

Make a function to compute the prior log-likelihood of the model parameters listed in the MADS problem dictionary madsdata

Methods:

  • Mads.makelogprior(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsFunc.jl:467

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Return:

  • the prior log-likelihood of the model parameters listed in the MADS problem dictionary madsdata
source
Mads.makemadscommandfunctionMethod

Make MADS function to execute the model defined in the input MADS problem dictionary

Methods:

  • Mads.makemadscommandfunction(madsdata_in::AbstractDict; obskeys, calczeroweightobs, calcpredictions, quiet) : /home/travis/build/madsjulia/Mads.jl/src/MadsFunc.jl:68

Arguments:

  • madsdata_in::AbstractDict

Keywords:

  • calcpredictions : Calculate predictions [default=true]
  • calczeroweightobs : Calculate zero weight observations [default=false]
  • obskeys
  • quiet

Example:

Mads.makemadscommandfunction(madsdata)

MADS can be coupled with any internal or external model. The model coupling is defined in the MADS problem dictionary. The expectations is that for a given set of model inputs, the model will produce a model output that will be provided to MADS. The fields in the MADS problem dictionary that can be used to define the model coupling are:

  • Model : execute a Julia function defined in an external input Julia file. The function that should accept a parameter dictionary with all the model parameters as an input argument and should return an observation dictionary with all the model predicted observations. MADS will execute the first function defined in the file.

  • MADS model : create a Julia function based on an external input Julia file. The input file should contain a function that accepts as an argument the MADS problem dictionary. MADS will execute the first function defined in the file. This function should create a Julia function that will accept a parameter dictionary with all the model parameters as an input argument and will return an observation dictionary with all the model predicted observations.

  • Julia model : execute an internal Julia function that accepts a parameter dictionary with all the model parameters as an input argument and will return an observation dictionary with all the model predicted observations.

  • Julia function : execute an internal Julia function that accepts a parameter vector with all the model parameters as an input argument and will return an observation vector with all the model predicted observations.

  • Command : execute an external UNIX command or script that will execute an external model.

  • Julia command : execute a Julia script that will execute an external model. The Julia script is defined in an external Julia file. The input file should contain a function that accepts a parameter dictionary with all the model parameters as an input argument; MADS will execute the first function defined in the file. The Julia script should be capable to (1) execute the model (making a system call of an external model), (2) parse the model outputs, (3) return an observation dictionary with model predictions.

Both Command and Julia command can use different approaches to pass model parameters to the external model.

Only Command uses different approaches to get back the model outputs.

The script defined under Julia command parses the model outputs using Julia.

The available options for writing model inputs and reading model outputs are as follows.

Options for writing model inputs:

  • Templates : template files for writing model input files as defined at http://madsjulia.github.io
  • ASCIIParameters : model parameters written in a ASCII file
  • JLDParameters : model parameters written in a JLD file
  • YAMLParameters : model parameters written in a YAML file
  • JSONParameters : model parameters written in a JSON file

Options for reading model outputs:

  • Instructions : instruction files for reading model output files as defined at http://madsjulia.github.io
  • ASCIIPredictions : model predictions read from a ASCII file
  • JLDPredictions : model predictions read from a JLD file
  • YAMLPredictions : model predictions read from a YAML file
  • JSONPredictions : model predictions read from a JSON file

Returns:

  • Mads function to execute a forward model simulation
source
Mads.makemadsconditionalloglikelihoodMethod

Make a function to compute the conditional log-likelihood of the model parameters conditioned on the model predictions/observations. Model parameters and observations are defined in the MADS problem dictionary madsdata.

Methods:

  • Mads.makemadsconditionalloglikelihood(madsdata::AbstractDict; weightfactor) : /home/travis/build/madsjulia/Mads.jl/src/MadsFunc.jl:490

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • weightfactor : Weight factor [default=1]

Return:

  • the conditional log-likelihood
source
Mads.makemadsloglikelihoodMethod

Make a function to compute the log-likelihood for a given set of model parameters, associated model predictions and existing observations. By default, the Log-likelihood function computed internally. The Log-likelihood can be constructed from an external Julia function defined the MADS problem dictionary under LogLikelihood or ConditionalLogLikelihood.

In the case of a LogLikelihood external Julia function, the first function in the file provided should be a function that takes as arguments:

  • dictionary of model parameters
  • dictionary of model predictions
  • dictionary of respective observations

In the case of a ConditionalLogLikelihood external Julia function, the first function in the file provided should be a function that takes as arguments:

  • dictionary of model predictions
  • dictionary of respective observations

Methods:

  • Mads.makemadsloglikelihood(madsdata::AbstractDict; weightfactor) : /home/travis/build/madsjulia/Mads.jl/src/MadsFunc.jl:535

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • weightfactor : Weight factor [default=1]

Returns:

  • the log-likelihood for a given set of model parameters
source
Mads.makemadsreusablefunctionFunction

Make Reusable Mads function to execute a forward model simulation (automatically restarts if restart data exists)

Methods:

  • Mads.makemadsreusablefunction(madsdata::AbstractDict, madscommandfunction::Function) : /home/travis/build/madsjulia/Mads.jl/src/MadsFunc.jl:339
  • Mads.makemadsreusablefunction(madsdata::AbstractDict, madscommandfunction::Function, suffix::AbstractString; usedict) : /home/travis/build/madsjulia/Mads.jl/src/MadsFunc.jl:339
  • Mads.makemadsreusablefunction(paramkeys::AbstractVector, obskeys::AbstractVector, madsdatarestart::Union{Bool, String}, madscommandfunction::Function, restartdir::AbstractString; usedict) : /home/travis/build/madsjulia/Mads.jl/src/MadsFunc.jl:342

Arguments:

  • madscommandfunction::Function : Mads function to execute a forward model simulation
  • madsdata::AbstractDict : MADS problem dictionary
  • madsdatarestart::Union{Bool, String} : Restart type (memory/disk) or on/off status
  • obskeys::AbstractVector : Dictionary of observation keys
  • paramkeys::AbstractVector : Dictionary of parameter keys
  • restartdir::AbstractString : Restart directory where the reusable model results are stored
  • suffix::AbstractString : Suffix to be added to the name of restart directory

Keywords:

  • usedict : Use dictionary [default=true]

Returns:

  • Reusable Mads function to execute a forward model simulation (automatically restarts if restart data exists)
source
Mads.makemoifunctionsMethod

Make forward model, gradient, objective functions needed for MathOptInterface optimization

Methods:

  • Mads.makemoifunctions(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsMathOptInterface.jl:90

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • forward model, gradient, objective functions
source
Mads.makepowellMethod

Make Powell test function for LM optimization

Methods:

  • Mads.makepowell(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:160

Arguments:

  • n::Integer : number of observations

Returns:

  • Powell test function for LM optimization
source
Mads.makepowell_gradientMethod

ake parameter gradients of the Powell test function for LM optimization

Methods:

  • Mads.makepowell_gradient(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:184

Arguments:

  • n::Integer : number of observations

Returns:

  • arameter gradients of the Powell test function for LM optimization
source
Mads.makerosenbrockMethod

Make Rosenbrock test function for LM optimization

Methods:

  • Mads.makerosenbrock(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:115

Arguments:

  • n::Integer : number of observations

Returns:

  • Rosenbrock test function for LM optimization
source
Mads.makerosenbrock_gradientMethod

Make parameter gradients of the Rosenbrock test function for LM optimization

Methods:

  • Mads.makerosenbrock_gradient(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:137

Arguments:

  • n::Integer : number of observations

Returns:

  • parameter gradients of the Rosenbrock test function for LM optimization
source
Mads.makerotatedhyperellipsoidMethod

Methods:

  • Mads.makerotatedhyperellipsoid(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:336

Arguments:

  • n::Integer : number of observations

Returns:

  • rotated hyperellipsoid
source
Mads.makerotatedhyperellipsoid_gradientMethod

Methods:

  • Mads.makerotatedhyperellipsoid_gradient(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:360

Arguments:

  • n::Integer : number of observations

Returns:

  • rotated hyperellipsoid gradient
source
Mads.makesphereMethod

Make sphere

Methods:

  • Mads.makesphere(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:215

Arguments:

  • n::Integer : number of observations

Returns:

  • sphere
source
Mads.makesphere_gradientMethod

Make sphere gradient

Methods:

  • Mads.makesphere_gradient(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:236

Arguments:

  • n::Integer : number of observations

Returns:

  • sphere gradient
source
Mads.makesumsquaresMethod

Methods:

  • Mads.makesumsquares(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:298

Arguments:

  • n::Integer : number of observations

Returns:

  • sumsquares
source
Mads.makesumsquares_gradientMethod

Methods:

  • Mads.makesumsquares_gradient(n::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:317

Arguments:

  • n::Integer : number of observations

Returns:

  • sumsquares gradient
source
Mads.makesvrmodelFunction

Make SVR model functions (executor and cleaner)

Methods:

  • Mads.makesvrmodel(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsSVR.jl:204
  • Mads.makesvrmodel(madsdata::AbstractDict, numberofsamples::Integer; check, addminmax, loadsvr, savesvr, svm_type, kernel_type, degree, gamma, coef0, C, nu, epsilon, cache_size, tol, shrinking, probability, verbose, seed) : /home/travis/build/madsjulia/Mads.jl/src/MadsSVR.jl:204

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • numberofsamples::Integer : number of samples [default=100]

Keywords:

  • C : cost; penalty parameter of the error term [default=1000.0]
  • addminmax : add parameter minimum / maximum range values in the training set [default=true]
  • cache_size : size of the kernel cache [default=100.0]
  • check : check SVR performance [default=false]
  • coef0 : independent term in kernel function; important only in POLY and SIGMOND kernel types [default=0]
  • degree : degree of the polynomial kernel [default=3]
  • epsilon : epsilon in the EPSILON_SVR model; defines an epsilon-tube within which no penalty is associated in the training loss function with points predicted within a distance epsilon from the actual value [default=0.001]
  • gamma : coefficient for RBF, POLY and SIGMOND kernel types [default=1/numberofsamples]
  • kernel_type : kernel type[default=SVR.RBF]
  • loadsvr : load SVR models [default=false]
  • nu : upper bound on the fraction of training errors / lower bound of the fraction of support vectors; acceptable range (0, 1]; applied if NU_SVR model [default=0.5]
  • probability : train to estimate probabilities [default=false]
  • savesvr : save SVR models [default=false]
  • seed : random seed [default=0]
  • shrinking : apply shrinking heuristic [default=true]
  • svm_type : SVM type [default=SVR.EPSILON_SVR]
  • tol : tolerance of termination criterion [default=0.001]
  • verbose : verbose output [default=false]

Returns:

  • function performing SVR predictions
  • function loading existing SVR models
  • function saving SVR models
  • function removing SVR models from the memory
source
Mads.maxtofloatmax!Method

Scale down values larger than max(Float32) in a dataframe df so that Gadfly can plot the data

Methods:

  • Mads.maxtofloatmax!(df::DataFrames.DataFrame) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:1110

Arguments:

  • df::DataFrames.DataFrame : dataframe
source
Mads.meshgridFunction

Create mesh grid

Methods:

  • Mads.meshgrid(nx::Number, ny::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:454
  • Mads.meshgrid(x::AbstractVector, y::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:447

Arguments:

  • nx::Number
  • ny::Number
  • x::AbstractVector : vector of grid x coordinates
  • y::AbstractVector : vector of grid y coordinates

Returns:

  • 2D grid coordinates based on the coordinates contained in vectors x and y
source
Mads.minimizeMethod

Minimize Julia function using a constrained Levenberg-Marquardt technique

Mads.calibrate(madsdata; tolX=1e-3, tolG=1e-6, maxEval=1000, maxIter=100, maxJacobians=100, lambda=100.0, lambda_mu=10.0, np_lambda=10, show_trace=false, usenaive=false)

Methods:

  • Mads.calibrate(madsdata::AbstractDict; tolX, tolG, tolOF, tolOFcount, minOF, maxEval, maxIter, maxJacobians, lambda, lambda_mu, np_lambda, show_trace, quiet, usenaive, save_results, localsa, parallel_optimization) : /home/travis/build/madsjulia/Mads.jl/src/MadsCalibrate.jl:195

Arguments:

  • madsdata::AbstractDict

Keywords:

  • lambda : initial Levenberg-Marquardt lambda [default=100.0]
  • lambda_mu : lambda multiplication factor [default=10.0]
  • localsa
  • maxEval : maximum number of model evaluations [default=1000]
  • maxIter : maximum number of optimization iterations [default=100]
  • maxJacobians : maximum number of Jacobian solves [default=100]
  • minOF : objective function update tolerance [default=1e-3]
  • np_lambda : number of parallel lambda solves [default=10]
  • parallel_optimization
  • quiet
  • save_results
  • show_trace : shows solution trace [default=false]
  • tolG : parameter space update tolerance [default=1e-6]
  • tolOF : objective function update tolerance [default=1e-3]
  • tolOFcount : number of Jacobian runs with small objective function change [default=5]
  • tolX : parameter space tolerance [default=1e-4]
  • usenaive

Returns:

  • vector with the optimal parameter values at the minimum
  • optimization algorithm results (e.g. results.minimizer)
source
Mads.mkdirMethod

Create a directory (if does not already exist)

Methods:

  • Mads.mkdir(dirname::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1502

Arguments:

  • dirname::AbstractString : directory
source
Mads.modelinformationcriteriaFunction

Model section information criteria

Methods:

  • Mads.modelinformationcriteria(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsModelSelection.jl:11
  • Mads.modelinformationcriteria(madsdata::AbstractDict, par::Array{Float64}) : /home/travis/build/madsjulia/Mads.jl/src/MadsModelSelection.jl:11

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • par::Array{Float64} : parameter array
source
Mads.modobsweights!Function

Modify (multiply) observation weights in the MADS problem dictionary

Methods:

  • Mads.modobsweights!(madsdata::AbstractDict, value::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:314
  • Mads.modobsweights!(madsdata::AbstractDict, value::Number, obskeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:314

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • obskeys::AbstractVector
  • value::Number : value for modifing observation weights
source
Mads.modwellweights!Function

Modify (multiply) well weights in the MADS problem dictionary

Methods:

  • Mads.modwellweights!(madsdata::AbstractDict, value::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:361
  • Mads.modwellweights!(madsdata::AbstractDict, value::Number, wellkeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:361

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • value::Number : value for well weights
  • wellkeys::AbstractVector
source
Mads.montecarloMethod

Monte Carlo analysis

Methods:

  • Mads.montecarlo(madsdata::AbstractDict; compute, N, filename) : /home/travis/build/madsjulia/Mads.jl/src/MadsMonteCarlo.jl:208

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • N : number of samples [default=100]
  • compute
  • filename : file name to save Monte-Carlo results

Returns:

  • parameter dictionary containing the data arrays

Dumps:

  • YAML output file with the parameter dictionary containing the data arrays

Example:

Mads.montecarlo(madsdata; N=100)
source
Mads.naive_get_deltaxMethod

Naive Levenberg-Marquardt optimization: get the LM parameter space step

Methods:

  • Mads.naive_get_deltax(JpJ::AbstractMatrix{Float64}, Jp::AbstractMatrix{Float64}, f0::AbstractVector{Float64}, lambda::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:264

Arguments:

  • Jp::AbstractMatrix{Float64} : Jacobian matrix times model parameters
  • JpJ::AbstractMatrix{Float64} : Jacobian matrix times model parameters times transposed Jacobian matrix
  • f0::AbstractVector{Float64} : initial model observations
  • lambda::Number : Levenberg-Marquardt lambda

Returns:

  • the LM parameter space step
source
Mads.naive_levenberg_marquardtFunction

Naive Levenberg-Marquardt optimization

Methods:

  • Mads.naive_levenberg_marquardt(f::Function, g::Function, x0::AbstractVector{Float64}) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:314
  • Mads.naive_levenberg_marquardt(f::Function, g::Function, x0::AbstractVector{Float64}, o::Function; maxIter, maxEval, lambda, lambda_mu, np_lambda) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:314

Arguments:

  • f::Function : forward model function
  • g::Function : gradient function for the forward model
  • o::Function : objective function [default=x->(x'*x)[1]]
  • x0::AbstractVector{Float64} : initial parameter guess

Keywords:

  • lambda : initial Levenberg-Marquardt lambda [default=100]
  • lambda_mu : lambda multiplication factor μ [default=10]
  • maxEval : maximum number of model evaluations [default=101]
  • maxIter : maximum number of optimization iterations [default=10]
  • np_lambda : number of parallel lambda solves [default=10]

Returns:

source
Mads.naive_lm_iterationMethod

Naive Levenberg-Marquardt optimization: perform LM iteration

Methods:

  • Mads.naive_lm_iteration(f::Function, g::Function, o::Function, x0::AbstractVector{Float64}, f0::AbstractVector{Float64}, lambdas::AbstractVector{Float64}) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:285

Arguments:

  • f0::AbstractVector{Float64} : initial model observations
  • f::Function : forward model function
  • g::Function : gradient function for the forward model
  • lambdas::AbstractVector{Float64} : Levenberg-Marquardt lambdas
  • o::Function : objective function
  • x0::AbstractVector{Float64} : initial parameter guess

Returns:

source
Mads.noplotMethod

Disable MADS plotting

Methods:

  • Mads.noplot() : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:239
source
Mads.notebookMethod

Execute Jupyter notebook in IJulia or as a script

Methods:

  • Mads.notebook(rootname::AbstractString; script, notebook_directory, check) : /home/travis/build/madsjulia/Mads.jl/src/MadsNotebooks.jl:20

Arguments:

  • rootname::AbstractString : notebook root name

Keywords:

  • check : check of notebook exists
  • notebook_directory : notebook directory
  • script : execute as a script
source
Mads.notebook_checkMethod

Check is Jupyter notebook exists

Methods:

  • Mads.notebook_check(rootname::AbstractString; notebook_directory) : /home/travis/build/madsjulia/Mads.jl/src/MadsNotebooks.jl:101

Arguments:

  • rootname::AbstractString : notebook root name

Keywords:

  • notebook_directory : notebook directory
source
Mads.notebook_exportMethod

Export Jupyter notebook in html, markdown, latex, and script versions

Methods:

  • Mads.notebook_export(rootname::AbstractString; notebook_directory) : /home/travis/build/madsjulia/Mads.jl/src/MadsNotebooks.jl:67

Arguments:

  • rootname::AbstractString : notebook root name

Keywords:

  • notebook_directory : notebook directory
source
Mads.notebooksMethod

Open Jupyter in the Mads notebook directory

Methods:

  • Mads.notebooks(; notebook_directory) : /home/travis/build/madsjulia/Mads.jl/src/MadsNotebooks.jl:52

Keywords:

  • notebook_directory : notebook directory
source
Mads.notebookscriptMethod

Execute Jupyter notebook as a script

Methods:

  • Mads.notebookscript(a...; script, notebook_directory, k...) : /home/travis/build/madsjulia/Mads.jl/src/MadsNotebooks.jl:9

Keywords:

  • notebook_directory : notebook directory
  • script : execute as a script
source
Mads.obslineoccursinMethod

Match an instruction line in the Mads instruction file with model input file

Methods:

  • Mads.obslineoccursin(obsline::AbstractString, regexs::Vector{Regex}) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1157

Arguments:

  • obsline::AbstractString : instruction line
  • regexs::Vector{Regex} : regular expressions

Returns:

  • true or false
source
Mads.ofFunction

Compute objective function

Methods:

  • Mads.of(madsdata::AbstractDict, d::AbstractDict; filter) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:54
  • Mads.of(madsdata::AbstractDict, resultvec::AbstractVector; filter) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:50
  • Mads.of(madsdata::AbstractDict; filter) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:65

Arguments:

  • d::AbstractDict
  • madsdata::AbstractDict : MADS problem dictionary
  • resultvec::AbstractVector : result vector

Keywords:

  • filter
source
Mads.parallel_optimization_offMethod

Turn off parallel optimization of jacobians and lambdas

Methods:

  • Mads.parallel_optimization_off() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:229
source
Mads.parallel_optimization_onMethod

Turn on parallel optimization of jacobians and lambdas

Methods:

  • Mads.parallel_optimization_on() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:220
source
Mads.paramarray2dictMethod

Convert a parameter array to a parameter dictionary of arrays

Methods:

  • Mads.paramarray2dict(madsdata::AbstractDict, array::Array) : /home/travis/build/madsjulia/Mads.jl/src/MadsMonteCarlo.jl:278

Arguments:

  • array::Array : parameter array
  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • a parameter dictionary of arrays
source
Mads.paramdict2arrayMethod

Convert a parameter dictionary of arrays to a parameter array

Methods:

  • Mads.paramdict2array(dict::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsMonteCarlo.jl:297

Arguments:

  • dict::AbstractDict : parameter dictionary of arrays

Returns:

  • a parameter array
source
Mads.parsemadsdata!Method

Parse loaded MADS problem dictionary

Methods:

  • Mads.parsemadsdata!(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:288

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.parsenodenamesFunction

Parse string with node names defined in SLURM

Methods:

  • Mads.parsenodenames(nodenames::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:208
  • Mads.parsenodenames(nodenames::AbstractString, ntasks_per_node::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:208

Arguments:

  • nodenames::AbstractString : string with node names defined in SLURM
  • ntasks_per_node::Integer : number of parallel tasks per node [default=1]

Returns:

  • vector with names of compute nodes (hosts)
source
Mads.partialofMethod

Compute the sum of squared residuals for observations that match a regular expression

Methods:

  • Mads.partialof(madsdata::AbstractDict, resultdict::AbstractDict, regex::Regex) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:91

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • regex::Regex : regular expression
  • resultdict::AbstractDict : result dictionary

Returns:

  • the sum of squared residuals for observations that match the regular expression
source
Mads.pkgversion_oldMethod

Get package version

Methods:

  • Mads.pkgversion_old(modulestr::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:545

Arguments:

  • modulestr::AbstractString

Returns:

  • package version
source
Mads.printSAresultsMethod

Print sensitivity analysis results

Methods:

  • Mads.printSAresults(madsdata::AbstractDict, results::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:946

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • results::AbstractDict : dictionary with sensitivity analysis results
source
Mads.printSAresults2Method

Print sensitivity analysis results (method 2)

Methods:

  • Mads.printSAresults2(madsdata::AbstractDict, results::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:1028

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • results::AbstractDict : dictionary with sensitivity analysis results
source
Mads.printerrormsgMethod

Print error message

Methods:

  • Mads.printerrormsg(errmsg) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:438

Arguments:

  • errmsg : error message
source
Mads.printobservationsFunction

Print (emit) observations in the MADS problem dictionary

Methods:

  • Mads.printobservations(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:435
  • Mads.printobservations(madsdata::AbstractDict, filename::AbstractString; json) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:443
  • Mads.printobservations(madsdata::AbstractDict, io::IO) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:435
  • Mads.printobservations(madsdata::AbstractDict, io::IO, obskeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:435

Arguments:

  • filename::AbstractString : output file name
  • io::IO : output stream
  • madsdata::AbstractDict : MADS problem dictionary
  • obskeys::AbstractVector

Keywords:

  • json
source
Mads.pullFunction

Pull (checkout) the latest version of Mads modules

Methods:

  • Mads.pull() : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:91
  • Mads.pull(modulename::AbstractString; kw...) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:91

Arguments:

  • modulename::AbstractString : module name
source
Mads.pushFunction

Push the latest version of Mads modules in the default remote repository

Methods:

  • Mads.push() : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:166
  • Mads.push(modulename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:166

Arguments:

  • modulename::AbstractString : module name
source
Mads.quietoffMethod

Make MADS not quiet

Methods:

  • Mads.quietoff() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:112
source
Mads.quietonMethod

Make MADS quiet

Methods:

  • Mads.quieton() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:103
source
Mads.readasciipredictionsMethod

Read MADS predictions from an ASCII file

Methods:

  • Mads.readasciipredictions(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsASCII.jl:43

Arguments:

  • filename::AbstractString : ASCII file name

Returns:

  • MADS predictions
source
Mads.readmodeloutputMethod

Read model outputs saved for MADS

Methods:

  • Mads.readmodeloutput(madsdata::AbstractDict; obskeys) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:910

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • obskeys : observation keys [default=getobskeys(madsdata)]
source
Mads.readobservationsFunction

Read observations

Methods:

  • Mads.readobservations(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1277
  • Mads.readobservations(madsdata::AbstractDict, obskeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1277

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • obskeys::AbstractVector : observation keys [default=getobskeys(madsdata)]

Returns:

  • dictionary with Mads observations
source
Mads.readobservations_cmadsMethod

Read observations using C MADS dynamic library

Methods:

  • Mads.readobservations_cmads(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsCMads.jl:13

Arguments:

  • madsdata::AbstractDict : Mads problem dictionary

Returns:

  • observations
source
Mads.readyamlpredictionsMethod

Read MADS model predictions from a YAML file filename

Methods:

  • Mads.readyamlpredictions(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsYAML.jl:104

Arguments:

  • filename::AbstractString : file name

Returns:

  • data in yaml input file
source
Mads.recursivemkdirMethod

Create directories recursively (if does not already exist)

Methods:

  • Mads.recursivemkdir(s::AbstractString; filename) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1514

Arguments:

  • s::AbstractString

Keywords:

  • filename
source
Mads.recursivermdirMethod

Remove directories recursively

Methods:

  • Mads.recursivermdir(s::AbstractString; filename) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1559

Arguments:

  • s::AbstractString

Keywords:

  • filename
source
Mads.regexs2obsMethod

Get observations for a set of regular expressions

Methods:

  • Mads.regexs2obs(obsline::AbstractString, regexs::Vector{Regex}, obsnames::Vector{String}, getparamhere::Vector{Bool}) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1178

Arguments:

  • getparamhere::Vector{Bool} : parameters
  • obsline::AbstractString : observation line
  • obsnames::Vector{String} : observation names
  • regexs::Vector{Regex} : regular expressions

Returns:

  • obsdict : observations
source
Mads.removesource!Function

Remove a contamination source

Methods:

  • Mads.removesource!(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsAnasol.jl:49
  • Mads.removesource!(madsdata::AbstractDict, sourceid::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsAnasol.jl:49

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • sourceid::Int64 : source id [default=0]
source
Mads.removesourceparameters!Method

Remove contaminant source parameters

Methods:

  • Mads.removesourceparameters!(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsAnasol.jl:134

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.requiredFunction

Lists modules required by a module (Mads by default)

Methods:

  • Mads.required() : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:45
  • Mads.required(modulename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:45
  • Mads.required(modulename::AbstractString, filtermodule::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:45

Arguments:

  • filtermodule::AbstractString : filter module name
  • modulename::AbstractString : module name [default="Mads"]

Returns:

  • filtered modules
source
Mads.resetmodelrunsMethod

Reset the model runs count to be equal to zero

Methods:

  • Mads.resetmodelruns() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:268
source
Mads.residualsFunction

Compute residuals

Methods:

  • Mads.residuals(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:32
  • Mads.residuals(madsdata::AbstractDict, resultdict::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:29
  • Mads.residuals(madsdata::AbstractDict, resultvec::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsLevenbergMarquardt.jl:6

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • resultdict::AbstractDict : result dictionary
  • resultvec::AbstractVector : result vector

Returns:

source
Mads.restartoffMethod

MADS restart off

Methods:

  • Mads.restartoff() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:84
source
Mads.restartonMethod

MADS restart on

Methods:

  • Mads.restarton() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:75
source
Mads.reweighsamplesMethod

Reweigh samples using importance sampling – returns a vector of log-likelihoods after reweighing

Methods:

  • Mads.reweighsamples(madsdata::AbstractDict, predictions::Array, oldllhoods::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:331

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • oldllhoods::AbstractVector : the log likelihoods of the parameters in the old distribution
  • predictions::Array : the model predictions for each of the samples

Returns:

  • vector of log-likelihoods after reweighing
source
Mads.rmdirMethod

Remove directory

Methods:

  • Mads.rmdir(dir::AbstractString; path) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1374

Arguments:

  • dir::AbstractString : directory to be removed

Keywords:

  • path : path of the directory [default=current path]
source
Mads.rmfileMethod

Remove file

Methods:

  • Mads.rmfile(filename::AbstractString; path) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1390

Arguments:

  • filename::AbstractString : file to be removed

Keywords:

  • path : path of the file [default=current path]
source
Mads.rmfilesMethod

Remove files

Methods:

  • Mads.rmfile(filename::AbstractString; path) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1390

Arguments:

  • filename::AbstractString

Keywords:

  • path : path of the file [default=current path]
source
Mads.rmfiles_extMethod

Remove files with extension ext

Methods:

  • Mads.rmfiles_ext(ext::AbstractString; path) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1419

Arguments:

  • ext::AbstractString : extension

Keywords:

  • path : path of the files to be removed [default=.]
source
Mads.rmfiles_rootMethod

Remove files with root root

Methods:

  • Mads.rmfiles_root(root::AbstractString; path) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1432

Arguments:

  • root::AbstractString : root

Keywords:

  • path : path of the files to be removed [default=.]
source
Mads.rosenbrockMethod

Rosenbrock test function

Methods:

  • Mads.rosenbrock(x::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:40

Arguments:

  • x::AbstractVector : parameter vector

Returns:

  • test result
source
Mads.rosenbrock2_gradient_lmMethod

Parameter gradients of the Rosenbrock test function

Methods:

  • Mads.rosenbrock2_gradient_lm(x::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:21

Arguments:

  • x::AbstractVector : parameter vector

Returns:

  • parameter gradients
source
Mads.rosenbrock2_lmMethod

Rosenbrock test function (more difficult to solve)

Methods:

  • Mads.rosenbrock2_lm(x::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:7

Arguments:

  • x::AbstractVector : parameter vector
source
Mads.rosenbrock_gradient!Method

Parameter gradients of the Rosenbrock test function

Methods:

  • Mads.rosenbrock_gradient!(x::AbstractVector, grad::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:65

Arguments:

  • grad::AbstractVector : gradient vector
  • x::AbstractVector : parameter vector
source
Mads.rosenbrock_gradient_lmMethod

Parameter gradients of the Rosenbrock test function for LM optimization (returns the gradients for the 2 components separately)

Methods:

  • Mads.rosenbrock_gradient_lm(x::AbstractVector; dx, center) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:82

Arguments:

  • x::AbstractVector : parameter vector

Keywords:

  • center : array with parameter observations at the center applied to compute numerical derivatives [default=Vector{Float64}(undef, 0)]
  • dx : apply parameter step to compute numerical derivatives [default=false]

Returns:

  • parameter gradients
source
Mads.rosenbrock_hessian!Method

Parameter Hessian of the Rosenbrock test function

Methods:

  • Mads.rosenbrock_hessian!(x::AbstractVector, hess::AbstractMatrix) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:98

Arguments:

  • hess::AbstractMatrix : Hessian matrix
  • x::AbstractVector : parameter vector
source
Mads.rosenbrock_lmMethod

Rosenbrock test function for LM optimization (returns the 2 components separately)

Methods:

  • Mads.rosenbrock_lm(x::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsTestFunctions.jl:54

Arguments:

  • x::AbstractVector : parameter vector

Returns:

  • test result
source
Mads.runcmdFunction

Run external command and pipe stdout and stderr

Methods:

  • Mads.runcmd(cmd::Cmd; quiet, pipe, waittime) : /home/travis/build/madsjulia/Mads.jl/src/MadsExecute.jl:39
  • Mads.runcmd(cmdstring::AbstractString; quiet, pipe, waittime) : /home/travis/build/madsjulia/Mads.jl/src/MadsExecute.jl:98

Arguments:

  • cmd::Cmd : command (as a julia command; e.g. `ls`)
  • cmdstring::AbstractString : command (as a string; e.g. "ls")

Keywords:

  • pipe : [default=false]
  • quiet : [default=Mads.quiet]
  • waittime : wait time is second [default=Mads.executionwaittime]

Returns:

  • command output
  • command error message
source
Mads.runremoteFunction

Run remote command on a series of servers

Methods:

  • Mads.runremote(cmd::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:284
  • Mads.runremote(cmd::AbstractString, nodenames::Vector{String}) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:284

Arguments:

  • cmd::AbstractString : remote command
  • nodenames::Vector{String} : names of machines/nodes [default=madsservers]

Returns:

  • output of running remote command
source
Mads.saltelliMethod

Saltelli sensitivity analysis

Methods:

  • Mads.saltelli(madsdata::AbstractDict; N, seed, rng, restartdir, parallel, checkpointfrequency, save, load) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:644

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • N : number of samples [default=100]
  • checkpointfrequency : check point frequency [default=N]
  • load
  • parallel : set to true if the model runs should be performed in parallel [default=false]
  • restartdir : directory where files will be stored containing model results for fast simulation restarts
  • rng
  • save
  • seed : random seed [default=0]
source
Mads.saltellibruteMethod

Saltelli sensitivity analysis (brute force)

Methods:

  • Mads.saltellibrute(madsdata::AbstractDict; N, seed, rng, restartdir) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:456

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • N : number of samples [default=1000]
  • restartdir : directory where files will be stored containing model results for fast simulation restarts
  • rng
  • seed : random seed [default=0]
source
Mads.samplingMethod

Methods:

  • Mads.sampling(param::AbstractVector, J::Array, numsamples::Number; seed, rng, scale) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:280

Arguments:

  • J::Array : Jacobian matrix
  • numsamples::Number : Number of samples
  • param::AbstractVector : Parameter vector

Keywords:

  • rng
  • scale : data scaling [default=1]
  • seed : random esee [default=0]

Returns:

  • generated samples (vector or array)
  • vector of log-likelihoods
source
Mads.savemadsfileFunction

Save MADS problem dictionary madsdata in MADS input file filename

Methods:

  • Mads.savemadsfile(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:432
  • Mads.savemadsfile(madsdata::AbstractDict, filename::AbstractString; observations_separate, filenameobs) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:432
  • Mads.savemadsfile(madsdata::AbstractDict, parameters::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:449
  • Mads.savemadsfile(madsdata::AbstractDict, parameters::AbstractDict, filename::AbstractString; explicit, observations_separate) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:449

Arguments:

  • filename::AbstractString : input file name (e.g. input_file_name.mads)
  • madsdata::AbstractDict : MADS problem dictionary
  • parameters::AbstractDict : Dictionary with parameters (optional)

Keywords:

  • explicit : if true ignores MADS YAML file modifications and rereads the original input file [default=false]
  • filenameobs
  • observations_separate

Example:

Mads.savemadsfile(madsdata)
Mads.savemadsfile(madsdata, "test.mads")
Mads.savemadsfile(madsdata, parameters, "test.mads")
Mads.savemadsfile(madsdata, parameters, "test.mads", explicit=true)
source
Mads.savemcmcresultsMethod

Save MCMC chain in a file

Methods:

  • Mads.savemcmcresults(chain::Array, filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsMonteCarlo.jl:163

Arguments:

  • chain::Array : MCMC chain
  • filename::AbstractString : file name

Dumps:

  • the file containing MCMC chain
source
Mads.savesaltellirestartMethod

Save Saltelli sensitivity analysis results for fast simulation restarts

Methods:

  • Mads.savesaltellirestart(evalmat::Array, matname::AbstractString, restartdir::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:625

Arguments:

  • evalmat::Array : saved array
  • matname::AbstractString : matrix (array) name (defines the name of the loaded file)
  • restartdir::AbstractString : directory where files will be stored containing model results for fast simulation restarts
source
Mads.searchdirFunction

Get files in the current directory or in a directory defined by path matching pattern key which can be a string or regular expression

Methods:

  • Mads.searchdir(key::AbstractString; path) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:956
  • Mads.searchdir(key::Regex; path) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:955

Arguments:

  • key::AbstractString : matching pattern for Mads input files (string or regular expression accepted)
  • key::Regex : matching pattern for Mads input files (string or regular expression accepted)

Keywords:

  • path : search directory for the mads input files [default=.]

Returns:

  • filename : an array with file names matching the pattern in the specified directory

Examples:

- `Mads.searchdir("a")`
- `Mads.searchdir(r"[A-B]"; path = ".")`
- `Mads.searchdir(r".*.cov"; path = ".")`
source
Mads.set_nprocs_per_taskFunction

Set number of processors needed for each parallel task at each node

Methods:

  • Mads.set_nprocs_per_task() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:66
  • Mads.set_nprocs_per_task(local_nprocs_per_task::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:66

Arguments:

  • local_nprocs_per_task::Integer
source
Mads.setallparamsoff!Method

Set all parameters OFF

Methods:

  • Mads.setallparamsoff!(madsdata::AbstractDict; filter) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:466

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • filter : parameter filter
source
Mads.setallparamson!Method

Set all parameters ON

Methods:

  • Mads.setallparamson!(madsdata::AbstractDict; filter) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:452

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary

Keywords:

  • filter : parameter filter
source
Mads.setdebuglevelMethod

Set MADS debug level

Methods:

  • Mads.setdebuglevel(level::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:239

Arguments:

  • level::Int64 : debug level
source
Mads.setdirFunction

Set the working directory (for parallel environments)

Methods:

  • Mads.setdir() : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:254
  • Mads.setdir(dir) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:249

Arguments:

  • dir : directory

Example:

@Distributed.everywhere Mads.setdir()
@Distributed.everywhere Mads.setdir("/home/monty")
source
Mads.setdpiMethod

Set image dpi

Methods:

  • Mads.setdpi(dpi::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:175

Arguments:

  • dpi::Integer
source
Mads.setexecutionwaittimeMethod

Set maximum execution wait time for forward model runs in seconds

Methods:

  • Mads.setexecutionwaittime(waitime::Float64) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:259

Arguments:

  • waitime::Float64 : maximum execution wait time for forward model runs in seconds
source
Mads.setmadsinputfileMethod

Set a default MADS input file

Methods:

  • Mads.setmadsinputfile(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:509

Arguments:

  • filename::AbstractString : input file name (e.g. input_file_name.mads)
source
Mads.setmadsserversFunction

Generate a list of Mads servers

Methods:

  • Mads.setmadsservers() : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:339
  • Mads.setmadsservers(first::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:339
  • Mads.setmadsservers(first::Int64, last::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:339

Arguments:

  • first::Int64 : first [default=0]
  • last::Int64 : last [default=18]

Returns

  • array string of mads servers
source
Mads.setmodelinputsFunction

Set model input files; delete files where model output should be saved for MADS

Methods:

  • Mads.setmodelinputs(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:822
  • Mads.setmodelinputs(madsdata::AbstractDict, parameters::AbstractDict; path) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:822

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • parameters::AbstractDict : parameters

Keywords:

  • path : path for the files [default=.]
source
Mads.setnewmadsfilenameFunction

Set new mads file name

Methods:

  • Mads.setnewmadsfilename(filename::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:672
  • Mads.setnewmadsfilename(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:669

Arguments:

  • filename::AbstractString : file name
  • madsdata::AbstractDict : MADS problem dictionary

Returns:

  • new file name
source
Mads.setobservationtargets!Method

Set observations (calibration targets) in the MADS problem dictionary based on a predictions dictionary

Methods:

  • Mads.setobservationtargets!(madsdata::AbstractDict, predictions::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:539

Arguments:

  • madsdata::AbstractDict : Mads problem dictionary
  • predictions::AbstractDict : dictionary with model predictions
source
Mads.setobstime!Function

Set observation time based on the observation name in the MADS problem dictionary

Methods:

  • Mads.setobstime!(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:250
  • Mads.setobstime!(madsdata::AbstractDict, rx::Regex) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:260
  • Mads.setobstime!(madsdata::AbstractDict, rx::Regex, obskeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:260
  • Mads.setobstime!(madsdata::AbstractDict, separator::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:250
  • Mads.setobstime!(madsdata::AbstractDict, separator::AbstractString, obskeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:250

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • obskeys::AbstractVector
  • rx::Regex : regular expression to match
  • separator::AbstractString : separator [default=_]

Examples:

Mads.setobstime!(madsdata, "_t")
Mads.setobstime!(madsdata, r"[A-x]*_t([0-9,.]+)")
source
Mads.setobsweights!Function

Set observation weights in the MADS problem dictionary

Methods:

  • Mads.setobsweights!(madsdata::AbstractDict, v::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:292
  • Mads.setobsweights!(madsdata::AbstractDict, v::AbstractVector, obskeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:292
  • Mads.setobsweights!(madsdata::AbstractDict, value::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:287
  • Mads.setobsweights!(madsdata::AbstractDict, value::Number, obskeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:287

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • obskeys::AbstractVector
  • v::AbstractVector : vector of observation weights
  • value::Number : value for observation weights
source
Mads.setparamoff!Method

Set a specific parameter with a key parameterkey OFF

Methods:

  • Mads.setparamoff!(madsdata::AbstractDict, parameterkey::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:491

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • parameterkey::AbstractString : parameter key
source
Mads.setparamon!Method

Set a specific parameter with a key parameterkey ON

Methods:

  • Mads.setparamon!(madsdata::AbstractDict, parameterkey::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:480

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • parameterkey::AbstractString : parameter key
source
Mads.setparamsdistnormal!Method

Set normal parameter distributions for all the model parameters in the MADS problem dictionary

Methods:

  • Mads.setparamsdistnormal!(madsdata::AbstractDict, mean::AbstractVector, stddev::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:503

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • mean::AbstractVector : array with the mean values
  • stddev::AbstractVector : array with the standard deviation values
source
Mads.setparamsdistuniform!Method

Set uniform parameter distributions for all the model parameters in the MADS problem dictionary

Methods:

  • Mads.setparamsdistuniform!(madsdata::AbstractDict, min::AbstractVector, max::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:518

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • max::AbstractVector : array with the maximum values
  • min::AbstractVector : array with the minimum values
source
Mads.setparamsinit!Function

Set initial optimized parameter guesses in the MADS problem dictionary

Methods:

  • Mads.setparamsinit!(madsdata::AbstractDict, paramdict::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:319
  • Mads.setparamsinit!(madsdata::AbstractDict, paramdict::AbstractDict, idx::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:319

Arguments:

  • idx::Int64 : index of the dictionary of arrays with initial model parameter values
  • madsdata::AbstractDict : MADS problem dictionary
  • paramdict::AbstractDict : dictionary with initial model parameter values
source
Mads.setprocsFunction

Set the available processors based on environmental variables (supports SLURM only at the moment)

Methods:

  • Mads.setprocs(; ntasks_per_node, nprocs_per_task, nodenames, mads_servers, test, quiet, veryquiet, dir, exename) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:47
  • Mads.setprocs(np::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:44
  • Mads.setprocs(np::Integer, nt::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsParallel.jl:31

Arguments:

  • np::Integer : number of processors [default=1]
  • nt::Integer : number of threads[default=1]

Keywords:

  • dir : common directory shared by all the jobs
  • exename : location of the julia executable (the same version of julia is needed on all the workers)
  • mads_servers : if true use MADS servers [default=false]
  • nodenames : array with names of machines/nodes to be invoked
  • nprocs_per_task : number of processors needed for each parallel task at each node [default=Mads.nprocs_per_task]
  • ntasks_per_node : number of parallel tasks per node [default=0]
  • quiet : suppress output [default=Mads.quiet]
  • test : test the servers and connect to each one ones at a time [default=false]
  • veryquiet

Returns:

  • vector with names of compute nodes (hosts)

Example:

Mads.setprocs()
Mads.setprocs(4)
Mads.setprocs(4, 8)
Mads.setprocs(ntasks_per_node=4)
Mads.setprocs(ntasks_per_node=32, mads_servers=true)
Mads.setprocs(ntasks_per_node=64, nodenames=madsservers)
Mads.setprocs(ntasks_per_node=64, nodenames=["madsmax", "madszem"])
Mads.setprocs(ntasks_per_node=64, nodenames="wc[096-157,160,175]")
Mads.setprocs(ntasks_per_node=64, mads_servers=true, exename="/home/monty/bin/julia", dir="/home/monty")
source
Mads.setseedFunction

Set / get current random seed. seed < 0 gets seed, anything else sets it.

Methods:

  • Mads.setseed() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:480
  • Mads.setseed(seed::Integer) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:480
  • Mads.setseed(seed::Integer, quiet::Bool; rng) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:480

Arguments:

  • quiet::Bool : [default=true]
  • seed::Integer : random seed

Keywords:

  • rng
source
Mads.setsourceinit!Function

Set initial optimized parameter guesses in the MADS problem dictionary for the Source class

Methods:

  • Mads.setparamsinit!(madsdata::AbstractDict, paramdict::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:319
  • Mads.setparamsinit!(madsdata::AbstractDict, paramdict::AbstractDict, idx::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:319

Arguments:

  • idx::Int64 : index of the dictionary of arrays with initial model parameter values
  • madsdata::AbstractDict : MADS problem dictionary
  • paramdict::AbstractDict : dictionary with initial model parameter values
source
Mads.settarget!Method

Set observation target

Methods:

  • Mads.settarget!(o::AbstractDict, target::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:240

Arguments:

  • o::AbstractDict : observation data
  • target::Number : observation target
source
Mads.settime!Method

Set observation time

Methods:

  • Mads.settime!(o::AbstractDict, time::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:162

Arguments:

  • o::AbstractDict : observation data
  • time::Number : observation time
source
Mads.setverbositylevelMethod

Set MADS verbosity level

Methods:

  • Mads.setverbositylevel(level::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:249

Arguments:

  • level::Int64 : debug level
source
Mads.setweight!Method

Set observation weight

Methods:

  • Mads.setweight!(o::AbstractDict, weight::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:201

Arguments:

  • o::AbstractDict : observation data
  • weight::Number : observation weight
source
Mads.setwellweights!Function

Set well weights in the MADS problem dictionary

Methods:

  • Mads.setwellweights!(madsdata::AbstractDict, value::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:343
  • Mads.setwellweights!(madsdata::AbstractDict, value::Number, wellkeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:343

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • value::Number : value for well weights
  • wellkeys::AbstractVector
source
Mads.showallparametersFunction

Show all parameters in the MADS problem dictionary

Methods:

  • Mads.showallparameters(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:579
  • Mads.showallparameters(madsdata::AbstractDict, parkeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:579
  • Mads.showallparameters(madsdata::AbstractDict, result::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:583

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • parkeys::AbstractVector
  • result::AbstractDict
source
Mads.showobservationsFunction

Show observations in the MADS problem dictionary

Methods:

  • Mads.showobservations(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:399
  • Mads.showobservations(madsdata::AbstractDict, obskeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:399

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • obskeys::AbstractVector
source
Mads.showparametersFunction

Show parameters in the MADS problem dictionary

Methods:

  • Mads.showparameters(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:565
  • Mads.showparameters(madsdata::AbstractDict, parkeys::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:565
  • Mads.showparameters(madsdata::AbstractDict, parkeys::AbstractVector, all::Bool) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:565
  • Mads.showparameters(madsdata::AbstractDict, result::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsParameters.jl:560

Arguments:

  • all::Bool
  • madsdata::AbstractDict : MADS problem dictionary
  • parkeys::AbstractVector
  • result::AbstractDict
source
Mads.sinetransformFunction

Sine transformation of model parameters

Methods:

  • Mads.sinetransform(madsdata::AbstractDict, params::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsSineTransformations.jl:33
  • Mads.sinetransform(sineparams::AbstractVector, lowerbounds::AbstractVector, upperbounds::AbstractVector, indexlogtransformed::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsSineTransformations.jl:43

Arguments:

  • indexlogtransformed::AbstractVector : index vector of log-transformed parameters
  • lowerbounds::AbstractVector : lower bounds
  • madsdata::AbstractDict : MADS problem dictionary
  • params::AbstractVector
  • sineparams::AbstractVector : model parameters
  • upperbounds::AbstractVector : upper bounds

Returns:

  • Sine transformation of model parameters
source
Mads.sinetransformfunctionMethod

Sine transformation of a function

Methods:

  • Mads.sinetransformfunction(f::Function, lowerbounds::AbstractVector, upperbounds::AbstractVector, indexlogtransformed::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsSineTransformations.jl:77

Arguments:

  • f::Function : function
  • indexlogtransformed::AbstractVector : index vector of log-transformed parameters
  • lowerbounds::AbstractVector : lower bounds
  • upperbounds::AbstractVector : upper bounds

Returns:

  • Sine transformation
source
Mads.sinetransformgradientMethod

Sine transformation of a gradient function

Methods:

  • Mads.sinetransformgradient(g::Function, lowerbounds::AbstractVector, upperbounds::AbstractVector, indexlogtransformed::AbstractVector; sindx) : /home/travis/build/madsjulia/Mads.jl/src/MadsSineTransformations.jl:98

Arguments:

  • g::Function : gradient function
  • indexlogtransformed::AbstractVector : index vector of log-transformed parameters
  • lowerbounds::AbstractVector : vector with parameter lower bounds
  • upperbounds::AbstractVector : vector with parameter upper bounds

Keywords:

  • sindx : sin-space parameter step applied to compute numerical derivatives [default=0.1]

Returns:

  • Sine transformation of a gradient function
source
Mads.sphericalcovMethod

Spherical spatial covariance function

Methods:

  • Mads.sphericalcov(h::Number, maxcov::Number, scale::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsKriging.jl:45

Arguments:

  • h::Number : separation distance
  • maxcov::Number : max covariance
  • scale::Number : scale

Returns:

  • covariance
source
Mads.sphericalvariogramMethod

Spherical variogram

Methods:

  • Mads.sphericalvariogram(h::Number, sill::Number, range::Number, nugget::Number) : /home/travis/build/madsjulia/Mads.jl/src/MadsKriging.jl:60

Arguments:

  • h::Number : separation distance
  • nugget::Number : nugget
  • range::Number : range
  • sill::Number : sill

Returns:

  • Spherical variogram
source
Mads.statusFunction

Status of Mads modules

Methods:

  • Mads.status(; git, gitmore) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:280
  • Mads.status(madsmodule::AbstractString; git, gitmore) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:285

Arguments:

  • madsmodule::AbstractString : mads module

Keywords:

  • git : use git [default=true or Mads.madsgit]
  • gitmore : use even more git [default=false]

Returns:

  • true or false
source
Mads.stderrcaptureoffMethod

Restore stderr

Methods:

  • Mads.stderrcaptureoff() : /home/travis/build/madsjulia/Mads.jl/src/MadsCapture.jl:137

Returns:

  • standered error
source
Mads.stderrcaptureonMethod

Redirect stderr to a reader

Methods:

  • Mads.stderrcaptureon() : /home/travis/build/madsjulia/Mads.jl/src/MadsCapture.jl:118
source
Mads.stdoutcaptureoffMethod

Restore stdout

Methods:

  • Mads.stdoutcaptureoff() : /home/travis/build/madsjulia/Mads.jl/src/MadsCapture.jl:103

Returns:

  • standered output
source
Mads.stdoutcaptureonMethod

Redirect stdout to a reader

Methods:

  • Mads.stdoutcaptureon() : /home/travis/build/madsjulia/Mads.jl/src/MadsCapture.jl:84
source
Mads.stdouterrcaptureoffMethod

Restore stdout & stderr

Methods:

  • Mads.stdouterrcaptureoff() : /home/travis/build/madsjulia/Mads.jl/src/MadsCapture.jl:168

Returns:

  • standered output amd standered error
source
Mads.stdouterrcaptureonMethod

Redirect stdout & stderr to readers

Methods:

  • Mads.stdouterrcaptureon() : /home/travis/build/madsjulia/Mads.jl/src/MadsCapture.jl:152
source
Mads.svrdumpMethod

Dump SVR models in files

Methods:

  • Mads.svrdump(svrmodel::Vector{SVR.svmmodel}, rootname::AbstractString, numberofsamples::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsSVR.jl:136

Arguments:

  • numberofsamples::Int64 : number of samples
  • rootname::AbstractString : root name
  • svrmodel::Vector{SVR.svmmodel} : array of SVR models
source
Mads.svrfreeMethod

Free SVR

Methods:

  • Mads.svrfree(svrmodel::Vector{SVR.svmmodel}) : /home/travis/build/madsjulia/Mads.jl/src/MadsSVR.jl:118

Arguments:

  • svrmodel::Vector{SVR.svmmodel} : array of SVR models
source
Mads.svrloadMethod

Load SVR models from files

Methods:

  • Mads.svrload(npred::Int64, rootname::AbstractString, numberofsamples::Int64) : /home/travis/build/madsjulia/Mads.jl/src/MadsSVR.jl:159

Arguments:

  • npred::Int64 : number of model predictions
  • numberofsamples::Int64 : number of samples
  • rootname::AbstractString : root name

Returns:

  • Array of SVR models for each model prediction
source
Mads.svrpredictionFunction

Predict SVR

Methods:

  • Mads.svrprediction(svrmodel::Vector{SVR.svmmodel}, paramarray::Matrix{Float64}) : /home/travis/build/madsjulia/Mads.jl/src/MadsSVR.jl:92

Arguments:

  • paramarray::Matrix{Float64} : parameter array
  • svrmodel::Vector{SVR.svmmodel} : array of SVR models

Returns:

  • SVR predicted observations (dependent variables) for a given set of parameters (independent variables)
source
Mads.svrtrainingFunction

Train SVR

Methods:

  • Mads.svrtraining(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsSVR.jl:37
  • Mads.svrtraining(madsdata::AbstractDict, numberofsamples::Integer; addminmax, kw...) : /home/travis/build/madsjulia/Mads.jl/src/MadsSVR.jl:37
  • Mads.svrtraining(madsdata::AbstractDict, paramarray::Matrix{Float64}; check, savesvr, addminmax, svm_type, kernel_type, degree, gamma, coef0, C, nu, cache_size, epsilon, shrinking, probability, verbose, tol) : /home/travis/build/madsjulia/Mads.jl/src/MadsSVR.jl:4

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • numberofsamples::Integer : number of random samples in the training set [default=100]
  • paramarray::Matrix{Float64}

Keywords:

  • C : cost; penalty parameter of the error term [default=1000.0]
  • addminmax : add parameter minimum / maximum range values in the training set [default=true]
  • cache_size : size of the kernel cache [default=100.0]
  • check : check SVR performance [default=false]
  • coef0 : independent term in kernel function; important only in POLY and SIGMOND kernel types [default=0]
  • degree : degree of the polynomial kernel [default=3]
  • epsilon : epsilon in the EPSILON_SVR model; defines an epsilon-tube within which no penalty is associated in the training loss function with points predicted within a distance epsilon from the actual value [default=0.001]
  • gamma : coefficient for RBF, POLY and SIGMOND kernel types [default=1/numberofsamples]
  • kernel_type : kernel type[default=SVR.RBF]
  • nu : upper bound on the fraction of training errors / lower bound of the fraction of support vectors; acceptable range (0, 1]; applied if NU_SVR model [default=0.5]
  • probability : train to estimate probabilities [default=false]
  • savesvr : save SVR models [default=false]
  • shrinking : apply shrinking heuristic [default=true]
  • svm_type : SVM type [default=SVR.EPSILON_SVR]
  • tol : tolerance of termination criterion [default=0.001]
  • verbose : verbose output [default=false]

Returns:

  • Array of SVR models
source
Mads.symlinkdirMethod

Create a symbolic link of a file filename in a directory dirtarget

Methods:

  • Mads.symlinkdir(filename::AbstractString, dirtarget::AbstractString, dirsource::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1360

Arguments:

  • dirsource::AbstractString
  • dirtarget::AbstractString : target directory
  • filename::AbstractString : file name
source
Mads.symlinkdirfilesMethod

Create a symbolic link of all the files in a directory dirsource in a directory dirtarget

Methods:

  • Mads.symlinkdirfiles(dirsource::AbstractString, dirtarget::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1342

Arguments:

  • dirsource::AbstractString : source directory
  • dirtarget::AbstractString : target directory
source
Mads.tagFunction

Tag Mads modules with a default argument :patch

Methods:

  • Mads.tag() : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:350
  • Mads.tag(madsmodule::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:355
  • Mads.tag(madsmodule::AbstractString, versionsym::Symbol) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:355
  • Mads.tag(versionsym::Symbol) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:350

Arguments:

  • madsmodule::AbstractString : mads module name
  • versionsym::Symbol : version symbol [default=:patch]
source
Mads.testFunction

Perform Mads tests (the tests will be in parallel if processors are defined; tests use the current Mads version in the workspace; reload("Mads.jl") if needed)

Methods:

  • Mads.test() : /home/travis/build/madsjulia/Mads.jl/src/MadsTest.jl:38
  • Mads.test(testname::AbstractString; madstest, plotting) : /home/travis/build/madsjulia/Mads.jl/src/MadsTest.jl:38

Arguments:

  • testname::AbstractString : name of the test to execute; module or example

Keywords:

  • madstest : test Mads [default=true]
  • plotting
source
Mads.testjFunction

Execute Mads tests using Julia Pkg.test (the default Pkg.test in Julia is executed in serial)

Methods:

  • Mads.testj() : /home/travis/build/madsjulia/Mads.jl/src/MadsTest.jl:9
  • Mads.testj(coverage::Bool) : /home/travis/build/madsjulia/Mads.jl/src/MadsTest.jl:9

Arguments:

  • coverage::Bool : [default=false]
source
Mads.transposematrixMethod

Transpose non-numeric matrix

Methods:

  • Mads.transposematrix(a::AbstractMatrix) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:428

Arguments:

  • a::AbstractMatrix : matrix
source
Mads.transposevectorMethod

Transpose non-numeric vector

Methods:

  • Mads.transposevector(a::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:418

Arguments:

  • a::AbstractVector : vector
source
Mads.untagMethod

Untag specific version

Methods:

  • Mads.untag(madsmodule::AbstractString, version::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsModules.jl:390

Arguments:

  • madsmodule::AbstractString : mads module name
  • version::AbstractString : version
source
Mads.vectoroffMethod

MADS vector calls off

Methods:

  • Mads.vectoroff() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:57
source
Mads.vectoronMethod

MADS vector calls on

Methods:

  • Mads.vectoron() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:48
source
Mads.veryquietoffMethod

Make MADS not very quiet

Methods:

  • Mads.veryquietoff() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:130
source
Mads.veryquietonMethod

Make MADS very quiet

Methods:

  • Mads.veryquieton() : /home/travis/build/madsjulia/Mads.jl/src/MadsHelpers.jl:121
source
Mads.void2nan!Method

Convert Nothing's into NaN's in a dictionary

Methods:

  • Mads.void2nan!(dict::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:1068

Arguments:

  • dict::AbstractDict : dictionary
source
Mads.weightedstatsMethod

Get weighted mean and variance samples

Methods:

  • Mads.weightedstats(samples::Array, llhoods::AbstractVector) : /home/travis/build/madsjulia/Mads.jl/src/MadsSensitivityAnalysis.jl:388

Arguments:

  • llhoods::AbstractVector : vector of log-likelihoods
  • samples::Array : array of samples

Returns:

  • vector of sample means
  • vector of sample variances
source
Mads.welloff!Method

Turn off a specific well in the MADS problem dictionary

Methods:

  • Mads.welloff!(madsdata::AbstractDict, wellname::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:632

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • wellname::AbstractString : name of the well to be turned off
source
Mads.wellon!Method

Turn on a specific well in the MADS problem dictionary

Methods:

  • Mads.wellon!(madsdata::AbstractDict, wellname::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:574

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • wellname::AbstractString : name of the well to be turned on
source
Mads.wellon!Method

Turn on a specific well in the MADS problem dictionary

Methods:

  • Mads.wellon!(madsdata::AbstractDict, rx::Regex) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:596
  • Mads.wellon!(madsdata::AbstractDict, wellname::AbstractString) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:574

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • rx::Regex
  • wellname::AbstractString : name of the well to be turned on
source
Mads.wells2observations!Method

Convert Wells class to Observations class in the MADS problem dictionary

Methods:

  • Mads.wells2observations!(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsObservations.jl:687

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
source
Mads.writeparametersFunction

Write model parameters

Methods:

  • Mads.writeparameters(madsdata::AbstractDict) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1076
  • Mads.writeparameters(madsdata::AbstractDict, parameters::AbstractDict; respect_space) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1076

Arguments:

  • madsdata::AbstractDict : MADS problem dictionary
  • parameters::AbstractDict : parameters

Keywords:

  • respect_space : respect provided space in the template file to fit model parameters [default=false]
source
Mads.writeparametersviatemplateMethod

Write parameters via MADS template (templatefilename) to an output file (outputfilename)

Methods:

  • Mads.writeparametersviatemplate(parameters, templatefilename, outputfilename; respect_space) : /home/travis/build/madsjulia/Mads.jl/src/MadsIO.jl:1020

Arguments:

  • outputfilename : output file name
  • parameters : parameters
  • templatefilename : tmplate file name

Keywords:

  • respect_space : respect provided space in the template file to fit model parameters [default=false]
source