mlpack
Namespaces | Functions
print_doc_functions_impl.hpp File Reference
#include <mlpack/core/util/hyphenate_string.hpp>
Include dependency graph for print_doc_functions_impl.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

 mlpack
 Linear algebra utility functions, generally performed on matrices or vectors.
 

Functions

std::string mlpack::bindings::cli::GetBindingName (const std::string &bindingName)
 Given the name of a binding, print its command-line name (this returns "mlpack_<bindingName>".
 
std::string mlpack::bindings::cli::PrintImport (const std::string &bindingName)
 Print any imports for CLI (there are none, so this returns an empty string).
 
std::string mlpack::bindings::cli::PrintInputOptionInfo ()
 Print any special information about input options.
 
std::string mlpack::bindings::cli::PrintOutputOptionInfo ()
 Print any special information about output options.
 
template<typename T >
std::string mlpack::bindings::cli::PrintValue (const T &value, bool quotes)
 Given a parameter type, print the corresponding value.
 
template<typename T >
std::string mlpack::bindings::cli::PrintValue (const std::vector< T > &value, bool quotes)
 Given a vector parameter type, print the corresponding value.
 
std::string mlpack::bindings::cli::PrintDefault (const std::string &paramName)
 Given a parameter name, print its corresponding default value.
 
std::string mlpack::bindings::cli::PrintDataset (const std::string &dataset)
 Print a dataset type parameter (add .csv and return).
 
std::string mlpack::bindings::cli::PrintModel (const std::string &model)
 Print a model type parameter (add .bin and return).
 
std::string mlpack::bindings::cli::ProcessOptions ()
 Base case for recursion.
 
template<typename T , typename... Args>
std::string mlpack::bindings::cli::ProcessOptions (const std::string &paramName, const T &value, Args... args)
 Print an option for a command-line argument.
 
template<typename... Args>
std::string mlpack::bindings::cli::ProgramCall (const std::string &programName, Args... args)
 Given a program name and arguments for it, print what its invocation would be.
 
std::string mlpack::bindings::cli::ProgramCall (const std::string &programName)
 Given a program name, print a program call invocation assuming that all options are specified.
 
std::string mlpack::bindings::cli::ParamString (const std::string &paramName)
 Print what a user would type to invoke the given option name. More...
 

Detailed Description

Author
Ryan Curtin

This will generate a string representing what a user should type to invoke a given option. For the command-line bindings, this will generate strings like '–param_name=x' or '–param_name'.

mlpack is free software; you may redistribute it and/or modify it under the terms of the 3-clause BSD license. You should have received a copy of the 3-clause BSD license along with mlpack. If not, see http://www.opensource.org/licenses/BSD-3-Clause for more information.

Function Documentation

◆ ParamString()

std::string mlpack::bindings::cli::ParamString ( const std::string &  paramName)
inline

Print what a user would type to invoke the given option name.

Note that the name must exist in the CLI module. (Note that because of the way BINDING_LONG_DESC() and BINDING_EXAMPLE() is structured, this doesn't mean that all of the PARAM_*() declarataions need to come before BINDING_LONG_DESC() and BINDING_EXAMPLE() declaration.)