Detailed Description
classifies constraints according to levenshtein distance graph of their names
Definition in file clscons_consnamelevenshtein.cpp.
#include "clscons_consnamelevenshtein.h"#include "cons_decomp.h"#include "cons_decomp.hpp"#include <vector>#include <stdio.h>#include <sstream>#include <queue>#include "class_detprobdata.h"#include "class_conspartition.h"#include "scip_misc.h"Go to the source code of this file.
Data Structures | |
| struct | DEC_ClassifierData |
Macros | |
| #define | DEC_CLASSIFIERNAME "consnamelevenshtein" |
| #define | DEC_DESC "constraint names (according to levenshtein distance graph)" |
| #define | DEC_PRIORITY 0 |
| #define | DEC_ENABLED FALSE |
| #define | classifierFree NULL |
Functions | |
| int | calcLevenshteinDistance (std::string s, std::string t) |
| static | DEC_DECL_CONSCLASSIFY (classifierClassify) |
| SCIP_RETCODE | SCIPincludeConsClassifierConsnameLevenshtein (SCIP *scip) |
Macro Definition Documentation
◆ DEC_CLASSIFIERNAME
| #define DEC_CLASSIFIERNAME "consnamelevenshtein" |
name of classifier
Definition at line 50 of file clscons_consnamelevenshtein.cpp.
◆ DEC_DESC
| #define DEC_DESC "constraint names (according to levenshtein distance graph)" |
short description of classification
Definition at line 51 of file clscons_consnamelevenshtein.cpp.
◆ DEC_PRIORITY
| #define DEC_PRIORITY 0 |
Definition at line 52 of file clscons_consnamelevenshtein.cpp.
◆ DEC_ENABLED
| #define DEC_ENABLED FALSE |
Definition at line 54 of file clscons_consnamelevenshtein.cpp.
◆ classifierFree
| #define classifierFree NULL |
destructor of classifier to free user data (called when GCG is exiting)
Definition at line 79 of file clscons_consnamelevenshtein.cpp.
Function Documentation
◆ calcLevenshteinDistance()
| int calcLevenshteinDistance | ( | std::string | s, |
| std::string | t | ||
| ) |
returns levenshtein distance between two strings
Definition at line 82 of file clscons_consnamelevenshtein.cpp.
Referenced by DEC_DECL_CONSCLASSIFY().
◆ DEC_DECL_CONSCLASSIFY()
|
static |
Definition at line 128 of file clscons_consnamelevenshtein.cpp.
References gcg::ConsPartition::addClass(), gcg::DETPROBDATA::addConsPartition(), gcg::ConsPartition::assignConsToClass(), gcg::BOTH, calcLevenshteinDistance(), GCGconshdlrDecompGetDetprobdataOrig(), GCGconshdlrDecompGetDetprobdataPresolved(), gcg::DETPROBDATA::getCons(), and gcg::DETPROBDATA::getNConss().
◆ SCIPincludeConsClassifierConsnameLevenshtein()
| SCIP_RETCODE SCIPincludeConsClassifierConsnameLevenshtein | ( | SCIP * | scip | ) |
creates the scip consnames no numbers classifier and includes it in SCIP
- Parameters
-
scip SCIP data structure
Definition at line 246 of file clscons_consnamelevenshtein.cpp.
References classifierFree, DEC_CLASSIFIERNAME, DEC_DESC, DEC_ENABLED, DEC_PRIORITY, and DECincludeConsClassifier().
Referenced by SCIPincludeGcgPlugins().
