From f7f208e0f52d97434d8a183470893d4172296557 Mon Sep 17 00:00:00 2001 From: Fan Jiang Date: Thu, 6 Jan 2022 20:12:10 -0500 Subject: [PATCH] remove Potentials.cpp --- gtsam/discrete/Potentials.cpp | 96 ----------------------------------- 1 file changed, 96 deletions(-) delete mode 100644 gtsam/discrete/Potentials.cpp diff --git a/gtsam/discrete/Potentials.cpp b/gtsam/discrete/Potentials.cpp deleted file mode 100644 index b0ddcc822..000000000 --- a/gtsam/discrete/Potentials.cpp +++ /dev/null @@ -1,96 +0,0 @@ -///* ---------------------------------------------------------------------------- -// -// * GTSAM Copyright 2010, Georgia Tech Research Corporation, -// * Atlanta, Georgia 30332-0415 -// * All Rights Reserved -// * Authors: Frank Dellaert, et al. (see THANKS for the full author list) -// -// * See LICENSE for the license information -// -// * -------------------------------------------------------------------------- */ -// -///** -// * @file Potentials.cpp -// * @date March 24, 2011 -// * @author Frank Dellaert -// */ -// -//#include -//#include -// -//#include -// -//#include -// -//using namespace std; -// -//namespace gtsam { -// -///* ************************************************************************* */ -//double Potentials::safe_div(const double& a, const double& b) { -// // cout << boost::format("%g / %g = %g\n") % a % b % ((a == 0) ? 0 : (a / b)); -// // The use for safe_div is when we divide the product factor by the sum -// // factor. If the product or sum is zero, we accord zero probability to the -// // event. -// return (a == 0 || b == 0) ? 0 : (a / b); -//} -// -///* ******************************************************************************** -// */ -//Potentials::Potentials() : ADT(1.0) {} -// -///* ******************************************************************************** -// */ -//Potentials::Potentials(const DiscreteKeys& keys, const ADT& decisionTree) -// : ADT(decisionTree), cardinalities_(keys.cardinalities()) {} -// -///* ************************************************************************* */ -//bool Potentials::equals(const Potentials& other, double tol) const { -// return ADT::equals(other, tol); -//} -// -///* ************************************************************************* */ -//void Potentials::print(const string& s, const KeyFormatter& formatter) const { -// cout << s << "\n Cardinalities: { "; -// for (const std::pair& key : cardinalities_) -// cout << formatter(key.first) << ":" << key.second << ", "; -// cout << "}" << endl; -// ADT::print(" ", formatter); -//} -//// -//// /* ************************************************************************* */ -//// template -//// void Potentials::remapIndices(const P& remapping) { -//// // Permute the _cardinalities (TODO: Inefficient Consider Improving) -//// DiscreteKeys keys; -//// map ordering; -//// -//// // Get the original keys from cardinalities_ -//// for(const DiscreteKey& key: cardinalities_) -//// keys & key; -//// -//// // Perform Permutation -//// for(DiscreteKey& key: keys) { -//// ordering[key.first] = remapping[key.first]; -//// key.first = ordering[key.first]; -//// } -//// -//// // Change *this -//// AlgebraicDecisionTree permuted((*this), ordering); -//// *this = permuted; -//// cardinalities_ = keys.cardinalities(); -//// } -//// -//// /* ************************************************************************* */ -//// void Potentials::permuteWithInverse(const Permutation& inversePermutation) { -//// remapIndices(inversePermutation); -//// } -//// -//// /* ************************************************************************* */ -//// void Potentials::reduceWithInverse(const internal::Reduction& inverseReduction) { -//// remapIndices(inverseReduction); -//// } -// -// /* ************************************************************************* */ -// -//} // namespace gtsam