Skip to content

Commit

Permalink
Small fixes.
Browse files Browse the repository at this point in the history
* Warnings fixes.

* Remove unused.
  • Loading branch information
iglesias authored Apr 23, 2024
1 parent 0ad0861 commit 6306c1c
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 5 deletions.
2 changes: 1 addition & 1 deletion include/tapkee/callbacks/eigen_callbacks.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ struct eigen_features_callback
eigen_features_callback(const tapkee::DenseMatrix& matrix) : feature_matrix(matrix){};
inline tapkee::IndexType dimension() const
{
return feature_matrix.rows();
return static_cast<tapkee::IndexType>(feature_matrix.rows());
}
inline void vector(tapkee::IndexType i, tapkee::DenseVector& v) const
{
Expand Down
1 change: 0 additions & 1 deletion include/tapkee/defines/random.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ inline ScalarType gaussian_random()
} while ((radius >= 1.0) || (radius == 0.0));
radius = std::sqrt(-2 * std::log(radius) / radius);
x *= radius;
y *= radius;
return x;
#endif
}
Expand Down
2 changes: 1 addition & 1 deletion include/tapkee/external/barnes_hut_sne/vptree.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ class DataPoint
}
int dimensionality() const
{
return _x.size();
return static_cast<int>(_x.size());
}
ScalarType x(int d) const
{
Expand Down
4 changes: 2 additions & 2 deletions include/tapkee/routines/manifold_sculpting.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -92,8 +92,8 @@ SparseMatrix neighbors_distances_matrix(RandomAccessIterator begin, RandomAccess

inline SparseMatrixNeighborsPair angles_matrix_and_neighbors(const Neighbors& neighbors, const DenseMatrix& data)
{
const IndexType k = neighbors[0].size();
const IndexType n_vectors = data.cols();
const IndexType k = static_cast<IndexType>(neighbors[0].size());
const IndexType n_vectors = static_cast<IndexType>(data.cols());

SparseTriplets sparse_triplets;
sparse_triplets.reserve(static_cast<size_t>(k) * n_vectors);
Expand Down

0 comments on commit 6306c1c

Please sign in to comment.