Skip to content
Permalink
Browse files

updated language in the help screen and file input box to match that …

…in the documentation
  • Loading branch information...
mlwright84 committed Aug 9, 2018
1 parent b72f6e5 commit 3db6a98be0e7420d7869ac0ff60af61ab5bbb806
Showing with 12 additions and 14 deletions.
  1. +1 −1 api.cpp
  2. +1 −1 computationthread.cpp
  3. +9 −9 console.cpp
  4. +1 −1 dataselectdialog.ui
  5. +0 −2 docs/about.rst
@@ -36,7 +36,7 @@ std::unique_ptr<ComputationResult> from_istream(std::istream &file) {
m3.convert(arrangementMessage);

} else {
throw std::runtime_error("Expected a precomputed RIVET file");
throw std::runtime_error("Expected a RIVET module invariants file");
}
return from_messages(templatePointsMessage, arrangementMessage);
}
@@ -67,7 +67,7 @@ void ComputationThread::run()

bool ComputationThread::is_precomputed(const std::string &file_name)
{
std::cerr << "Checking if precomputed" << std::endl;
std::cerr << "Checking for a module invariants file" << std::endl;
std::ifstream file(file_name);
if (!file.is_open()) {
throw std::runtime_error("Couldn't open " + file_name + " for reading");
@@ -46,14 +46,14 @@ static const char USAGE[] =
rivet_console <input_file> --identify
rivet_console <input_file> --minpres [-H <dimension>] [-V <verbosity>] [-x <xbins>] [-y <ybins>] [--koszul]
rivet_console <input_file> [output_file] --betti [-H <dimension>] [-V <verbosity>] [-x <xbins>] [-y <ybins>] [--koszul]
rivet_console <precomputed_file> --bounds [-V <verbosity>]
rivet_console <precomputed_file> --barcodes <line_file> [-V <verbosity>]
rivet_console <module_invariants_file> --bounds [-V <verbosity>]
rivet_console <module_invariants_file> --barcodes <line_file> [-V <verbosity>]
rivet_console <input_file> <output_file> [-H <dimension>] [-V <verbosity>] [-x <xbins>] [-y <ybins>] [-f <format>] [--binary] [--koszul]
Options:
<input_file> A text file with suitably formatted point cloud, bifiltration, or
finite metric space as described at http://rivet.online/doc/input-data/
<precomputed_file> A precomputed RIVET file, as generated by this program by processing an
<module_invariants_file> A module invariants file, as generated by this program by processing an
<input_file>
-h --help Show this screen
--version Show the version
@@ -67,7 +67,7 @@ static const char USAGE[] =
--minpres Print the minimal presentation, then exit.
-b --betti Print dimension and Betti number information. Optionally, also save this info
to a file in a binary format for later viewing in the visualizer. Then exit.
--bounds Print lower and upper bounds for the module in <precomputed_file> and exit
--bounds Print lower and upper bounds for the module in <module_invariants_file> and exit
-k --koszul Use koszul homology-based algorithm to compute Betti numbers, instead of
an approach based on computing presentations.
--barcodes <line_file> Print barcodes for the line queries in line_file, then exit.
@@ -266,11 +266,11 @@ int main(int argc, char* argv[])

if (args["<input_file>"].isString()) {
params.fileName = args["<input_file>"].asString();
} else if (args["<precomputed_file>"].isString()) {
params.fileName = args["<precomputed_file>"].asString();
} else if (args["<module_invariants_file>"].isString()) {
params.fileName = args["<module_invariants_file>"].asString();
} else {
//This should never happen if docopt is doing its job and the docstring is written correctly
throw std::runtime_error("Either <input_file> or <precomputed_file> must be supplied");
throw std::runtime_error("Either <input_file> or <module_invariants_file> must be supplied");
}
docopt::value& out_file_name = args["<output_file>"];
if (out_file_name.isString()) {
@@ -419,7 +419,7 @@ int main(int argc, char* argv[])

if (barcodes || bounds) {
if (content.type != FileContentType::PRECOMPUTED) {
input_error("This function requires a precomputed RIVET file as input");
input_error("This function requires a RIVET module invariants file as input.");
return 1;
}
if (barcodes) {
@@ -431,7 +431,7 @@ int main(int argc, char* argv[])
}
} else {
if (content.type != FileContentType::DATA) {
input_error("This function requires a data file, not a precomputed RIVET file");
input_error("This function requires a data file, not a RIVET module invariants file.");
return 1;
}
content.result = computation.compute(*content.input_data, koszul);
@@ -261,7 +261,7 @@
</rect>
</property>
<property name="text">
<string>You can start from a point cloud, a bifiltration, or a file of precomputed RIVET data.</string>
<string>You can start from a point cloud, finite metric space, bifiltration, FIRep, or a module invariants file.</string>
</property>
<property name="alignment">
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>
@@ -96,8 +96,6 @@ Major Formatting todos:

Content Todos:

* some language in rivet_console --h needs to be edited to sync properly with the new changes to the documentation.
* similarly, language of file dialogue box should be updated.
* The text is not updated to explain how the persistence diagram window works in Simon's improvements to the visualization. (Right now there is a disclaimier about this.)
* I suggest to not print out xi_0, xi_1, and xi_2 when —Betti is called.
* The example could use some polish. More examples are desirable.

0 comments on commit 3db6a98

Please sign in to comment.
You can’t perform that action at this time.