File tree 2 files changed +8
-3
lines changed
include/albatross/src/models 2 files changed +8
-3
lines changed Original file line number Diff line number Diff line change @@ -23,6 +23,10 @@ struct ConditionalFit {
23
23
class ConditionalGaussian : public ModelBase <ConditionalGaussian> {
24
24
25
25
public:
26
+ ConditionalGaussian (JointDistribution &&prior,
27
+ const MarginalDistribution &truth)
28
+ : prior_(std::move(prior)), truth_(truth) {}
29
+
26
30
ConditionalGaussian (const JointDistribution &prior,
27
31
const MarginalDistribution &truth)
28
32
: prior_(prior), truth_(truth) {}
Original file line number Diff line number Diff line change @@ -109,17 +109,18 @@ struct AlwaysAcceptCandidateMetric {
109
109
};
110
110
111
111
template <typename InlierMetric, typename ConsensusMetric,
112
- typename IsValidCandidateMetric, typename GroupKey>
112
+ typename IsValidCandidateMetric, typename GroupKey,
113
+ typename PriorDistribution>
113
114
inline RansacFunctions<ConditionalFit, GroupKey> get_gp_ransac_functions (
114
- const JointDistribution &prior, const MarginalDistribution &truth,
115
+ PriorDistribution & &prior, const MarginalDistribution &truth,
115
116
const GroupIndexer<GroupKey> &indexer, const InlierMetric &inlier_metric,
116
117
const ConsensusMetric &consensus_metric,
117
118
const IsValidCandidateMetric &is_valid_candidate_metric) {
118
119
119
120
static_assert (is_prediction_metric<InlierMetric>::value,
120
121
" InlierMetric must be an PredictionMetric." );
121
122
122
- const ConditionalGaussian model (prior, truth);
123
+ const ConditionalGaussian model (std::forward<PriorDistribution>( prior) , truth);
123
124
124
125
const auto fitter = get_gp_ransac_fitter<GroupKey>(model, indexer);
125
126
You can’t perform that action at this time.
0 commit comments