summaryrefslogtreecommitdiff
path: root/src/Cech_complex/utilities/cech_persistence.cpp
diff options
context:
space:
mode:
authorvrouvrea <vrouvrea@636b058d-ea47-450e-bf9e-a15bfbe3eedb>2018-02-22 23:16:55 +0000
committervrouvrea <vrouvrea@636b058d-ea47-450e-bf9e-a15bfbe3eedb>2018-02-22 23:16:55 +0000
commit3cd1e01f0b0d4fdb46f49ec640c389374ca2fe70 (patch)
treeafe2bec947f098942d021e62d62546d56b9acabd /src/Cech_complex/utilities/cech_persistence.cpp
parentd57e3dfbf15f8aaa3afa097a4e3ed49cd23d26ea (diff)
Fix Cech with radius distance
Add a meta generation script for off_file_generator git-svn-id: svn+ssh://scm.gforge.inria.fr/svnroot/gudhi/branches/cechcomplex_vincent@3256 636b058d-ea47-450e-bf9e-a15bfbe3eedb Former-commit-id: fb13baa124ddc97c0dc61835ab0c72595d666155
Diffstat (limited to 'src/Cech_complex/utilities/cech_persistence.cpp')
-rw-r--r--src/Cech_complex/utilities/cech_persistence.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/Cech_complex/utilities/cech_persistence.cpp b/src/Cech_complex/utilities/cech_persistence.cpp
index e93596d4..93a200ff 100644
--- a/src/Cech_complex/utilities/cech_persistence.cpp
+++ b/src/Cech_complex/utilities/cech_persistence.cpp
@@ -43,20 +43,20 @@ using Field_Zp = Gudhi::persistent_cohomology::Field_Zp;
using Persistent_cohomology = Gudhi::persistent_cohomology::Persistent_cohomology<Simplex_tree, Field_Zp>;
void program_options(int argc, char* argv[], std::string& off_file_points, std::string& filediag,
- Filtration_value& threshold, int& dim_max, int& p, Filtration_value& min_persistence);
+ Filtration_value& max_radius, int& dim_max, int& p, Filtration_value& min_persistence);
int main(int argc, char* argv[]) {
std::string off_file_points;
std::string filediag;
- Filtration_value threshold;
+ Filtration_value max_radius;
int dim_max;
int p;
Filtration_value min_persistence;
- program_options(argc, argv, off_file_points, filediag, threshold, dim_max, p, min_persistence);
+ program_options(argc, argv, off_file_points, filediag, max_radius, dim_max, p, min_persistence);
Points_off_reader off_reader(off_file_points);
- Cech_complex cech_complex_from_file(off_reader.get_point_cloud(), threshold, Gudhi::Euclidean_distance());
+ Cech_complex cech_complex_from_file(off_reader.get_point_cloud(), max_radius);
// Construct the Cech complex in a Simplex Tree
Simplex_tree simplex_tree;
@@ -88,7 +88,7 @@ int main(int argc, char* argv[]) {
}
void program_options(int argc, char* argv[], std::string& off_file_points, std::string& filediag,
- Filtration_value& threshold, int& dim_max, int& p, Filtration_value& min_persistence) {
+ Filtration_value& max_radius, int& dim_max, int& p, Filtration_value& min_persistence) {
namespace po = boost::program_options;
po::options_description hidden("Hidden options");
hidden.add_options()("input-file", po::value<std::string>(&off_file_points),
@@ -98,8 +98,8 @@ void program_options(int argc, char* argv[], std::string& off_file_points, std::
visible.add_options()("help,h", "produce help message")(
"output-file,o", po::value<std::string>(&filediag)->default_value(std::string()),
"Name of file in which the persistence diagram is written. Default print in std::cout")(
- "max-edge-length,r",
- po::value<Filtration_value>(&threshold)->default_value(std::numeric_limits<Filtration_value>::infinity()),
+ "max-radius,r",
+ po::value<Filtration_value>(&max_radius)->default_value(std::numeric_limits<Filtration_value>::infinity()),
"Maximal length of an edge for the Cech complex construction.")(
"cpx-dimension,d", po::value<int>(&dim_max)->default_value(1),
"Maximal dimension of the Cech complex we want to compute.")(