Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion NOTICE
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
Apache DataSketches C++ and Python
Copyright 2022 The Apache Software Foundation
Copyright 2023 The Apache Software Foundation

Copyright 2015-2018 Yahoo Inc.
Copyright 2019-2020 Verizon Media
Expand Down
2 changes: 1 addition & 1 deletion cpc/include/cpc_compressor_impl.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@ uint8_t cpc_compressor<A>::determine_pseudo_phase(uint8_t lg_k, uint32_t c) {
if (lg_k < 4) throw std::logic_error("lgK < 4");
const size_t tmp = c >> (lg_k - 4);
const uint8_t phase = tmp & 15;
if (phase < 0 || phase >= 16) throw std::out_of_range("wrong phase");
if (phase >= 16) throw std::out_of_range("wrong phase");
return phase;
}
}
Expand Down
4 changes: 2 additions & 2 deletions python/src/vector_of_kll.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ class vector_of_kll_sketches {
std::string to_string(bool print_levels = false, bool print_items = false) const;

// binary output/input
py::list serialize(py::array_t<uint32_t>& isk);
py::list serialize(const py::array_t<int>& isk);
// note: deserialize() replaces the sketch at the specified
// index. Not a static method.
void deserialize(const py::bytes& sk_bytes, uint32_t idx);
Expand Down Expand Up @@ -404,7 +404,7 @@ void vector_of_kll_sketches<T, C>::deserialize(const py::bytes& sk_bytes,
}

template<typename T, typename C>
py::list vector_of_kll_sketches<T, C>::serialize(py::array_t<uint32_t>& isk) {
py::list vector_of_kll_sketches<T, C>::serialize(const py::array_t<int>& isk) {
std::vector<uint32_t> inds = get_indices(isk);
const size_t num_sketches = inds.size();

Expand Down