[mlpack-git] [mlpack/mlpack] Modeling LSH For Performance Tuning (#749)
notifications at github.com
Sat Aug 13 12:01:54 EDT 2016
> +template <typename SortPolicy, typename ObjectiveFunction>
> +void LSHModel<SortPolicy, ObjectiveFunction>::Train(
> + const arma::mat &referenceSet,
> + const double sampleRate,
> + const size_t k)
> + // Sanity check - sample rate must be in (0, 1].
> + if (sampleRate > 1 || sampleRate <= 0)
> + Log::Fatal << "Sampling rate must be floating point number in (0, 1]"
> + << std::endl;
> + // Update the object's max K value information.
> + maxKValue = k;
> + // Save pointer to training set.
> + this->referenceSet = &referenceSet;
Don't forget to update `ownsSet` here, and possibly delete the old reference set first.
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the mlpack-git