ParaMonte MATLAB 3.0.0
Parallel Monte Carlo and Machine Learning Library
See the latest version documentation.
FileContentsReport Class Reference

This is the base class for generating objects that contain the contents of a report file generated by a ParaMonte sampler.
More...

Inheritance diagram for FileContentsReport:
Collaboration diagram for FileContentsReport:

Public Member Functions

function FileContentsReport (in file, in silent, in method)
 Return a scalar object of class pm.sampling.FileContentsReport.
More...
 
function isdesc (in self, in record)
 
function skipNull (in self, in ibeg)
 
function skipFull (in self, in ibeg)
 

Static Public Member Functions

static function concat (in lines)
 

Data Fields

Property stats
 
Property contents
 
Property lineList
 
Property vis
 
Property banner
 
Property lineListLen
 
Property indentLen
 
Property dsymLen
 
Property dsym
 
Property prefix
 
Property method
 

Detailed Description

This is the base class for generating objects that contain the contents of a report file generated by a ParaMonte sampler.

This class is meant to be primarily internally used by the ParaMonte MATLAB library samplers.
See the documentation of the class constructor.

Note
See below for information on the attributes (properties).
See below for information on the methods.


Final Remarks


If you believe this algorithm or its documentation can be improved, we appreciate your contribution and help to edit this page's documentation and source file on GitHub.
For details on the naming abbreviations, see this page.
For details on the naming conventions, see this page.
This software is distributed under the MIT license with additional terms outlined below.

  1. If you use any parts or concepts from this library to any extent, please acknowledge the usage by citing the relevant publications of the ParaMonte library.
  2. If you regenerate any parts/ideas from this library in a programming environment other than those currently supported by this ParaMonte library (i.e., other than C, C++, Fortran, MATLAB, Python, R), please also ask the end users to cite this original ParaMonte library.

This software is available to the public under a highly permissive license.
Help us justify its continued development and maintenance by acknowledging its benefit to society, distributing it, and contributing to it.

Author:
Joshua Alexander Osborne, May 21 2024, 1:13 AM, University of Texas at Arlington
Fatemeh Bagheri, May 20 2024, 1:25 PM, NASA Goddard Space Flight Center (GSFC), Washington, D.C.
Amir Shahmoradi, May 16 2016, 9:03 AM, Oden Institute for Computational Engineering and Sciences (ICES), UT Austin

Definition at line 23 of file FileContentsReport.m.

Constructor & Destructor Documentation

◆ FileContentsReport()

function FileContentsReport::FileContentsReport ( in  file,
in  silent,
in  method 
)

Return a scalar object of class pm.sampling.FileContentsReport.

This is the constructor of the class pm.sampling.FileContentsReport.

Parameters
[in]file: The input scalar MATLAB string containing the path to an external report file.
[in]silent: See the corresponding argument of pm.io.FileContents class.
(optional. The default is set by pm.io.FileContents.)
[in]method: The input scalar MATLAB string containing the sampling method name.
The input value must be any of the following:
  1. "ParaDRAM"
  2. "ParaDISE"
  3. "ParaNest"
(optional. If missing, some of the report file contents may not be properly parsed.)
Returns
self : The output scalar object of class pm.sampling.FileContentsReport.


Possible calling interfaces

contents = pm.sampling.FileContentsReport(file)
contents = pm.sampling.FileContentsReport(file, [])
contents = pm.sampling.FileContentsReport(file, silent)
contents = pm.sampling.FileContentsReport(file, [], [])
contents = pm.sampling.FileContentsReport(file, silent, [])
contents = pm.sampling.FileContentsReport(file, silent, method)


Example usage

1cd(fileparts(mfilename('fullpath'))); % Change working directory to source code directory.
2addpath('../../../'); % Add the ParaMonte library root directory to the search path.
3
4%%%%
5%%%% Setup the sampler.
6%%%%
7
8sampler = pm.sampling.Paradram();
9sampler.spec.outputStatus = "retry";
10
11%%%%
12%%%% Run the sampler.
13%%%%
14
15sampler.run ( @(x) pm.stats.dist.himmelblau.getLogUDF(x(1), x(2)) ...
16 , 2 ...
17 );
18
19%%%%
20%%%% Ensure postprocessing the output report file is done by only
21%%%% one parallel process if distributed (MPI) parallelism is enabled.
22%%%%
23
24if pm.lib.mpi.runtime.rankp1() == 1
25
26 report = sampler.readReport();
27 report = report{1};
28
29 for parcond = ["sameeff", "zeroeff"]
30 report.stats.parallelism.speedup.scaling.strong.(parcond).vis.lineScatter.make();
31 report.stats.parallelism.speedup.scaling.strong.(parcond).vis.lineScatter.savefig("Paradram.himmelblau.parallelism.speedup.scaling.strong." + parcond + ".png", "-m3");
32 end
33
34end
function parallel()
Return a scalar MATLAB logical that is true if and only if the current installation of MATLAB contain...
function root()
Return a scalar MATLAB string containing the root directory of the ParaMonte library package.

Visualization of the example output




Final Remarks


If you believe this algorithm or its documentation can be improved, we appreciate your contribution and help to edit this page's documentation and source file on GitHub.
For details on the naming abbreviations, see this page.
For details on the naming conventions, see this page.
This software is distributed under the MIT license with additional terms outlined below.

  1. If you use any parts or concepts from this library to any extent, please acknowledge the usage by citing the relevant publications of the ParaMonte library.
  2. If you regenerate any parts/ideas from this library in a programming environment other than those currently supported by this ParaMonte library (i.e., other than C, C++, Fortran, MATLAB, Python, R), please also ask the end users to cite this original ParaMonte library.

This software is available to the public under a highly permissive license.
Help us justify its continued development and maintenance by acknowledging its benefit to society, distributing it, and contributing to it.

Author:
Joshua Alexander Osborne, May 21 2024, 1:30 AM, University of Texas at Arlington
Fatemeh Bagheri, May 20 2024, 1:25 PM, NASA Goddard Space Flight Center (GSFC), Washington, D.C.
Amir Shahmoradi, May 16 2016, 9:03 AM, Oden Institute for Computational Engineering and Sciences (ICES), UT Austin

Member Function Documentation

◆ concat()

static function FileContentsReport::concat ( in  lines)
static

◆ isdesc()

function FileContentsReport::isdesc ( in  self,
in  record 
)

◆ skipFull()

function FileContentsReport::skipFull ( in  self,
in  ibeg 
)

◆ skipNull()

function FileContentsReport::skipNull ( in  self,
in  ibeg 
)

Field Documentation

◆ banner

Property FileContentsReport::banner

banner

The scalar MATLAB string containing the ParaMonte library banner as appearing in the report file.

Definition at line 69 of file FileContentsReport.m.

◆ contents

Property FileContentsReport::contents

contents

The scalar MATLAB string containing the entire contents of the report file with all Carriage Return characters removed (relevant only to Windows OS).

Definition at line 44 of file FileContentsReport.m.

◆ dsym

Property FileContentsReport::dsym

dsym

The scalar MATLAB string representing the decoration symbol used in the report file, to be determined at runtime (currently %).
This is an internal class variable inaccessible to the end users.

Definition at line 119 of file FileContentsReport.m.

◆ dsymLen

Property FileContentsReport::dsymLen

dsymLen

The scalar MATLAB integer representing the minimum length of two of decoration symbols.
This is an internal class variable inaccessible to the end users.

Definition at line 110 of file FileContentsReport.m.

◆ indentLen

Property FileContentsReport::indentLen

indentLen

The scalar MATLAB integer representing the number of indentation characters at the beginning of each description line in the report file.
This is an internal class variable inaccessible to the end users.

Definition at line 102 of file FileContentsReport.m.

◆ lineList

Property FileContentsReport::lineList

lineList

The vector of MATLAB strings containing the set of all lines in the report file with all Carriage Return and New Line characters removed.

Definition at line 53 of file FileContentsReport.m.

◆ lineListLen

Property FileContentsReport::lineListLen

lineListLen

This is an internal class variable inaccessible to the end users.

Definition at line 93 of file FileContentsReport.m.

◆ method

Property FileContentsReport::method

method

The scalar MATLAB string representing the sample name.
This is an internal class variable inaccessible to the end users.

Definition at line 135 of file FileContentsReport.m.

◆ prefix

Property FileContentsReport::prefix

prefix

The scalar MATLAB string representing the prefix used in the description lines of the report file.
This is an internal class variable inaccessible to the end users.

Definition at line 127 of file FileContentsReport.m.

◆ stats

Property FileContentsReport::stats

stats

The scalar MATLAB struct containing the set of computed properties extracted from the report file.

Definition at line 35 of file FileContentsReport.m.

◆ vis

Property FileContentsReport::vis

vis

The scalar MATLAB struct containing the set of predefined visualizations for the output data.

Definition at line 61 of file FileContentsReport.m.


The documentation for this class was generated from the following file: