GraphChi  0.1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Macros
Classes | Macros | Typedefs | Functions | Variables
als.hpp File Reference
#include <assert.h>
#include <cmath>
#include <errno.h>
#include <string>
#include <stdint.h>
#include "matrixmarket/mmio.h"
#include "matrixmarket/mmio.c"
#include "api/chifilenames.hpp"
#include "api/vertex_aggregator.hpp"
#include "preprocessing/sharder.hpp"
#include "Eigen/Dense"
#include "Eigen/Sparse"
#include "Eigen/Cholesky"
#include "Eigen/Eigenvalues"
#include "Eigen/SVD"

Go to the source code of this file.

Classes

struct  latentvec_t
struct  als_factor_and_weight
struct  MMOutputter

Macros

#define EIGEN_YES_I_KNOW_SPARSE_MODULE_IS_NOT_STABLE_YET
#define NLATENT   5

Typedefs

typedef MatrixXd mat
typedef VectorXd vec
typedef VectorXi ivec
typedef MatrixXi imat
typedef SparseVector< double > sparse_vec

Functions

template<typename als_edge_type >
int convert_matrixmarket_for_ALS (std::string base_filename)
void output_als_result (std::string filename, vid_t numvertices, vid_t max_left_vertex)

Variables

double LAMBDA = 0.065
double rmse = 0.0
 RMSE computation.
mutex rmselock
vid_t max_left_vertex = 0
vid_t max_right_vertex = 0

Detailed Description

Author:
Aapo Kyrola akyro.nosp@m.la@c.nosp@m.s.cmu.nosp@m..edu
Version:
1.0

LICENSE

Copyright [2012] [Aapo Kyrola, Guy Blelloch, Carlos Guestrin / Carnegie Mellon University]

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

DESCRIPTION

Common code for ALS implementations.


Function Documentation

template<typename als_edge_type >
int convert_matrixmarket_for_ALS ( std::string  base_filename)

Create a bipartite graph from a matrix. Each row corresponds to vertex with the same id as the row number (0-based), but vertices correponsing to columns have id + num-rows.

Create sharder object