Skip to content

Commit

Permalink
removed old files
Browse files Browse the repository at this point in the history
  • Loading branch information
lambday authored and karlnapf committed Jul 1, 2016
1 parent 11fbddd commit 391f644
Show file tree
Hide file tree
Showing 73 changed files with 88 additions and 7,138 deletions.
Expand Up @@ -19,15 +19,15 @@
#include <algorithm>
#include <shogun/lib/SGVector.h>
#include <shogun/mathematics/Math.h>
#include <shogun/statistics/experimental/HypothesisTestExp.h>
#include <shogun/statistics/experimental/internals/TestTypes.h>
#include <shogun/statistics/experimental/internals/DataManager.h>
#include <shogun/statistics/experimental/internals/KernelManager.h>
#include <shogun/hypothsistest/experimental/HypothesisTest.h>
#include <shogun/hypothsistest/experimental/internals/TestTypes.h>
#include <shogun/hypothsistest/experimental/internals/DataManager.h>
#include <shogun/hypothsistest/experimental/internals/KernelManager.h>

using namespace shogun;
using namespace internal;

struct CHypothesisTestExp::Self
struct CHypothesisTest::Self
{
Self(index_t num_distributions, index_t num_kernels)
: data_manager(num_distributions), kernel_manager(num_kernels)
Expand All @@ -37,36 +37,36 @@ struct CHypothesisTestExp::Self
KernelManager kernel_manager;
};

CHypothesisTestExp::CHypothesisTestExp(index_t num_distributions, index_t num_kernels) : CSGObject()
CHypothesisTest::CHypothesisTest(index_t num_distributions, index_t num_kernels) : CSGObject()
{
self = std::unique_ptr<Self>(new CHypothesisTestExp::Self(num_distributions, num_kernels));
self = std::unique_ptr<Self>(new CHypothesisTest::Self(num_distributions, num_kernels));
}

CHypothesisTestExp::~CHypothesisTestExp()
CHypothesisTest::~CHypothesisTest()
{
}

DataManager& CHypothesisTestExp::get_data_manager()
DataManager& CHypothesisTest::get_data_manager()
{
return self->data_manager;
}

const DataManager& CHypothesisTestExp::get_data_manager() const
const DataManager& CHypothesisTest::get_data_manager() const
{
return self->data_manager;
}

KernelManager& CHypothesisTestExp::get_kernel_manager()
KernelManager& CHypothesisTest::get_kernel_manager()
{
return self->kernel_manager;
}

const KernelManager& CHypothesisTestExp::get_kernel_manager() const
const KernelManager& CHypothesisTest::get_kernel_manager() const
{
return self->kernel_manager;
}

float64_t CHypothesisTestExp::compute_p_value(float64_t statistic)
float64_t CHypothesisTest::compute_p_value(float64_t statistic)
{
SGVector<float64_t> values = sample_null();

Expand All @@ -76,7 +76,7 @@ float64_t CHypothesisTestExp::compute_p_value(float64_t statistic)
return 1.0 - i / values.vlen;
}

float64_t CHypothesisTestExp::compute_threshold(float64_t alpha)
float64_t CHypothesisTest::compute_threshold(float64_t alpha)
{
float64_t result = 0;
SGVector<float64_t> values = sample_null();
Expand All @@ -85,18 +85,18 @@ float64_t CHypothesisTestExp::compute_threshold(float64_t alpha)
return values[index_t(CMath::floor(values.vlen * (1 - alpha)))];
}

float64_t CHypothesisTestExp::perform_test()
float64_t CHypothesisTest::perform_test()
{
return compute_p_value(compute_statistic());
}

bool CHypothesisTestExp::perform_test(float64_t alpha)
bool CHypothesisTest::perform_test(float64_t alpha)
{
float64_t p_value = perform_test();
return p_value < alpha;
}

const char* CHypothesisTestExp::get_name() const
const char* CHypothesisTest::get_name() const
{
return "HypothesisTestExp";
return "HypothesisTest";
}
Expand Up @@ -16,8 +16,8 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/

#ifndef HYPOTHESIS_TEST_EXP_H_
#define HYPOTHESIS_TEST_EXP_H_
#ifndef HYPOTHESIS_TEST_H_
#define HYPOTHESIS_TEST_H_

#include <memory>
#include <shogun/lib/config.h>
Expand All @@ -36,11 +36,11 @@ class KernelManager;

}

class CHypothesisTestExp : public CSGObject
class CHypothesisTest : public CSGObject
{
public:
CHypothesisTestExp(index_t num_distributions, index_t num_kernels);
virtual ~CHypothesisTestExp();
CHypothesisTest(index_t num_distributions, index_t num_kernels);
virtual ~CHypothesisTest();

virtual float64_t compute_statistic() = 0;

Expand All @@ -66,4 +66,4 @@ class CHypothesisTestExp : public CSGObject

}

#endif // HYPOTHESIS_TEST_EXP_H_
#endif // HYPOTHESIS_TEST_H_
Expand Up @@ -28,7 +28,7 @@
* either expressed or implied, of the Shogun Development Team.
*/

#include <shogun/statistics/experimental/internals/BlockwiseDetails.h>
#include <shogun/hypothsistest/internals/BlockwiseDetails.h>

using namespace shogun;
using namespace internal;
Expand Down
Expand Up @@ -13,12 +13,12 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#include <shogun/lib/SGMatrix.h>
#include <shogun/statistics/experimental/internals/ComputationManager.h>
#include <shogun/statistics/experimental/internals/mmd/UnbiasedFull.h>
#include <shogun/hypothsistest/internals/ComputationManager.h>
#include <shogun/hypothsistest/internals/mmd/UnbiasedFull.h>

using namespace shogun;
using namespace internal;
Expand Down Expand Up @@ -53,7 +53,7 @@ void ComputationManager::compute()
std::vector<float64_t> results;
if (gpu)
{
// TODO results = operation.compute_using_gpu(kernel_matrices);
/ TODO results = operation.compute_using_gpu(kernel_matrices);
}
else
{
Expand Down
Expand Up @@ -13,7 +13,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#ifndef COMPUTATION_MANAGER_H__
Expand Down
Expand Up @@ -13,12 +13,12 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#include <algorithm>
#include <shogun/features/Features.h>
#include <shogun/statistics/experimental/internals/DataFetcher.h>
#include <shogun/hypothsistest/internals/DataFetcher.h>


using namespace shogun;
Expand Down
Expand Up @@ -30,7 +30,7 @@

#include <memory>
#include <shogun/lib/common.h>
#include <shogun/statistics/experimental/internals/BlockwiseDetails.h>
#include <shogun/hypothsistest/internals/BlockwiseDetails.h>

#ifndef DATA_FETCHER_H__
#define DATA_FETCHER_H__
Expand Down
Expand Up @@ -13,14 +13,14 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#include <shogun/features/Features.h>
#include <shogun/features/streaming/StreamingFeatures.h>
#include <shogun/statistics/experimental/internals/DataFetcher.h>
#include <shogun/statistics/experimental/internals/StreamingDataFetcher.h>
#include <shogun/statistics/experimental/internals/DataFetcherFactory.h>
#include <shogun/hypothsistest/internals/DataFetcher.h>
#include <shogun/hypothsistest/internals/StreamingDataFetcher.h>
#include <shogun/hypothsistest/internals/DataFetcherFactory.h>

using namespace shogun;
using namespace internal;
Expand Down
Expand Up @@ -13,7 +13,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#include <memory>
Expand Down
Expand Up @@ -13,14 +13,14 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#include <iostream> // TODO remove
#include <shogun/statistics/experimental/internals/DataManager.h>
#include <shogun/statistics/experimental/internals/NextSamples.h>
#include <shogun/statistics/experimental/internals/DataFetcher.h>
#include <shogun/statistics/experimental/internals/DataFetcherFactory.h>
#include <shogun/hypothsistest/internals/DataManager.h>
#include <shogun/hypothsistest/internals/NextSamples.h>
#include <shogun/hypothsistest/internals/DataFetcher.h>
#include <shogun/hypothsistest/internals/DataFetcherFactory.h>
#include <shogun/features/Features.h>

using namespace shogun;
Expand Down
Expand Up @@ -13,15 +13,15 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#ifndef DATA_MANAGER_H__
#define DATA_MANAGER_H__

#include <vector>
#include <memory>
#include <shogun/statistics/experimental/internals/InitPerFeature.h>
#include <shogun/hypothsistest/internals/InitPerFeature.h>
#include <shogun/lib/common.h>

namespace shogun
Expand Down
Expand Up @@ -13,13 +13,13 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#include <iostream> // TODO remove
#include <shogun/statistics/experimental/internals/InitPerFeature.h>
#include <shogun/statistics/experimental/internals/DataFetcher.h>
#include <shogun/statistics/experimental/internals/DataFetcherFactory.h>
#include <shogun/hypothsistest/internals/InitPerFeature.h>
#include <shogun/hypothsistest/internals/DataFetcher.h>
#include <shogun/hypothsistest/internals/DataFetcherFactory.h>
#include <shogun/features/Features.h>

using namespace shogun;
Expand Down
Expand Up @@ -13,7 +13,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#ifndef INIT_PER_FEATURE_H__
Expand Down Expand Up @@ -51,4 +51,3 @@ class InitPerFeature
}

#endif // INIT_PER_FEATURE_H__

Expand Up @@ -13,11 +13,11 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#include <shogun/kernel/Kernel.h>
#include <shogun/statistics/experimental/internals/InitPerKernel.h>
#include <shogun/hypothsistest/internals/InitPerKernel.h>

using namespace shogun;
using namespace internal;
Expand Down
Expand Up @@ -13,7 +13,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#ifndef INIT_PER_KERNEL_H__
Expand Down
Expand Up @@ -13,15 +13,15 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#include <vector>
#include <memory>
#include <iostream>
#include <shogun/kernel/Kernel.h>
#include <shogun/kernel/CustomKernel.h>
#include <shogun/statistics/experimental/internals/KernelManager.h>
#include <shogun/hypothsistest/internals/KernelManager.h>

using namespace shogun;
using namespace internal;
Expand Down
Expand Up @@ -13,7 +13,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#ifndef KERNEL_MANAGER_H__
Expand All @@ -22,7 +22,7 @@
#include <vector>
#include <memory>
#include <shogun/lib/common.h>
#include <shogun/statistics/experimental/internals/InitPerKernel.h>
#include <shogun/hypothsistest/internals/InitPerKernel.h>

namespace shogun
{
Expand Down
Expand Up @@ -13,12 +13,12 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#include <algorithm>
#include <iostream>
#include <shogun/statistics/experimental/internals/NextSamples.h>
#include <shogun/hypothsistest/internals/NextSamples.h>
#include <shogun/features/Features.h>

using namespace shogun;
Expand Down
Expand Up @@ -13,7 +13,7 @@
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
* along with this program. If not, see <http:/www.gnu.org/licenses/>.
*/

#ifndef NEXT_SAMPLES_H__
Expand Down Expand Up @@ -49,7 +49,7 @@ namespace internal
* {
* auto first = next_samples[0];
* auto second = next_samples[1];
* auto third = next_samples[2]; // Runtime Error
* auto third = next_samples[2]; / Runtime Error
* }
* @endcode
*/
Expand Down

0 comments on commit 391f644

Please sign in to comment.