Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Release candidate v1.0.0 #94

Merged
merged 79 commits into from
Jan 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
79 commits
Select commit Hold shift + click to select a range
4f5a935
PKG: Switch to pyrpoject based setup with scikit-core
RUrlus Dec 22, 2023
0586413
MAINT: Switch to python and extension directory layouts
RUrlus Dec 22, 2023
ed3975c
CICD: Update actions to new setup
RUrlus Dec 22, 2023
321feb7
BREAK: Rename and refactor awesome_cossim_topn to (what it does) spar…
RUrlus Dec 22, 2023
209e9d0
STY: [C++] Add style and formatting configs
RUrlus Dec 23, 2023
6e8f63c
BLD: [C++] Set up basis for nanobind bindings
RUrlus Dec 23, 2023
16aa4cd
ENH: [C++] Add bindings for sparse_dot_topn
RUrlus Dec 23, 2023
db7ba4f
MAINT: [C++] Rename base func to sp_matmul_topn
RUrlus Jan 2, 2024
613eb25
MAINT: Rename base func to sp_matmul_topn
RUrlus Jan 2, 2024
607ad65
BLD: [C++] Add flags to default build
RUrlus Jan 2, 2024
285d324
CHG: Support disabling the threshold properly
RUrlus Jan 2, 2024
553d896
TST: Add test fixtures
RUrlus Jan 2, 2024
d90e045
BLD: [C++] Move CMake modules into subdirectory
RUrlus Jan 2, 2024
aad472f
BLD: Specify directories to include in the sdist
RUrlus Jan 2, 2024
820ac34
ENH: Add ability for users to set the index dtype
RUrlus Jan 3, 2024
743d7ec
FIX: Catch case where shapes and storage are transpose compatible
RUrlus Jan 3, 2024
3dc8470
TST: Add tests for sp_matmul_topn
RUrlus Jan 3, 2024
47e963e
CHG: redirect `awsome_comssim_topn` to `sp_matmul_topn` with a deprec…
RUrlus Jan 3, 2024
84e4d61
ENH: Guard against a too large top_n value
RUrlus Jan 4, 2024
8e56c42
ENH: [C++] Add Min-Max Heap to retain top n scores
RUrlus Jan 4, 2024
4efab54
CHG: [C++] Switch to more efficient MaxHeap over keeping all candidat…
RUrlus Jan 4, 2024
ce3371f
TST: Maintain insertion order when taking the top n values
RUrlus Jan 4, 2024
52d5e5c
BLD: [C++] Search for Homebrew OpenMP on ARM MacOS
RUrlus Jan 4, 2024
56aeed6
ENH: [C++] Add OpenMP multithreaded implementation
RUrlus Jan 8, 2024
712f1d2
ENH: Add multithreaded implementation
RUrlus Jan 8, 2024
254cb9d
TST: Add tests for threaded variant
RUrlus Jan 8, 2024
8006bec
CHG: [C++] Allocate elements of C with known size and return
RUrlus Jan 8, 2024
dee6e5e
ENH: [C++] Enable users to specify the expected density and allocated…
RUrlus Jan 8, 2024
8ca36e3
API: Enable users to specify the expected density
RUrlus Jan 8, 2024
e068468
TST: Add tests for density paramter
RUrlus Jan 8, 2024
be43c2c
ENH: [C++] Add ability to return matrix with rows sorted
RUrlus Jan 9, 2024
004f562
ENH: Add option to return sorted matrix
RUrlus Jan 9, 2024
dc0d0c6
TST: Add test for sorted option
RUrlus Jan 9, 2024
c7851d0
CHG: Make deprecation warning softer and increase backward compatibility
RUrlus Jan 9, 2024
2cd266e
FIX: Set N-1 logical cores when n_threads is -1
RUrlus Jan 9, 2024
fe05daa
ENH: Add thin wrappers for iterative applications
RUrlus Jan 9, 2024
f1cb679
DEP: Add psutil as dependency to check the systems logical cores
RUrlus Jan 9, 2024
9e4b732
CICD: Explicitly disable architecture flags for wheels
RUrlus Jan 9, 2024
570d6e1
BLD: [C++] Improve handling of architecure flags on Apple ARM
RUrlus Jan 9, 2024
0cc28e2
CHG: Change argument order for backward compatibility
RUrlus Jan 10, 2024
ce31910
DOC: Redirect to readme for migration guide
RUrlus Jan 10, 2024
ebc11c1
DOC: Remove outdated default in docstring
RUrlus Jan 10, 2024
b7da4e9
DOC: Update README and add migration and contributing guides
RUrlus Jan 10, 2024
8bedefb
REL: Create release candidate for v1.0.0
RUrlus Jan 10, 2024
de9edd6
DOC: Add warning to the README
RUrlus Jan 10, 2024
4522c80
TST: Use package scope for rng fixtures
RUrlus Jan 11, 2024
f4eb2a8
ENH: [C++] Add function to compute result size of C
RUrlus Jan 12, 2024
876ac2e
CHG: [C++] Make threshold argument optional
RUrlus Jan 12, 2024
d95aedb
ENH: [C++] Pre-compute size of C when threshold is None
RUrlus Jan 12, 2024
9b72472
CHG: Handle None value for threshold on C++ side
RUrlus Jan 12, 2024
932644d
BLD: [C++] Strip OpenMP flag for clangd
RUrlus Jan 12, 2024
155ddf6
DOC: Attribute modified source code
RUrlus Jan 16, 2024
dab999f
FIX: [C++] Add missing include for memcopy
RUrlus Jan 22, 2024
6d414a9
CICD: Fix pytest command typo
RUrlus Jan 22, 2024
e1baba7
CICD: Set MacOS deployment target to get C++17 support
RUrlus Jan 22, 2024
e398817
CICD: Restrict wheels to CPython as we depend on Scipy
RUrlus Jan 22, 2024
415117e
CICD: Set CI Buildwheel options in pyproject.toml
RUrlus Jan 22, 2024
44fc84d
BLD: [C++] Inform about OpenMP status
RUrlus Jan 22, 2024
18ed989
BLD: [C++] Add Windows support for architecture flags
RUrlus Jan 22, 2024
cdd0e39
CICD: Silence warnings about testing ARM wheels on Intel hardware
RUrlus Jan 22, 2024
f098847
CICD: Add explicit repair wheel commands
RUrlus Jan 22, 2024
d2480c7
CICD: Vendor OpenMP in the wheels
RUrlus Jan 22, 2024
6eed2b1
CICD: Do not set deployment target manually
RUrlus Jan 22, 2024
8cd8fc8
BLD: Set default deployment target
RUrlus Jan 22, 2024
8c3ab36
CICD: Test against all Python versions for PRs
RUrlus Jan 22, 2024
4628e1f
CICD: Combine non-vendored wheels into single directory
RUrlus Jan 22, 2024
07dfeb4
DOC: Move detailed intallation information to a seperate file
RUrlus Jan 22, 2024
875e0ed
BLD: [C++] Use SIMD detection routines from the Point Cloud Library (…
RUrlus Jan 22, 2024
207942a
CHG: [C++] Move out general functionality to common
RUrlus Jan 23, 2024
26b4bb1
FIX: [C++] Correct recounting of columns for row sums
RUrlus Jan 23, 2024
f73db93
ENH: [C++] Add sp_matmul and parallel variant sp_matmul
RUrlus Jan 23, 2024
ee58547
ENH: Add sp_matmul and pass through when topn is equal to number of c…
RUrlus Jan 23, 2024
a41657c
DOC: Add benchmark code and instructions
RUrlus Jan 23, 2024
e8eb183
BLD: [C++] Fix SIMD checks for Apple Intel
RUrlus Jan 24, 2024
9b36167
DOC: Update documentation and benchmark results
RUrlus Jan 24, 2024
764489a
TST: Add tests for sp_matmul
RUrlus Jan 25, 2024
0024322
TST: Add pytest config
RUrlus Jan 25, 2024
7af66b1
REL: Release v1.0.0
RUrlus Jan 31, 2024
3a9279f
CICD: Switch to manual install of CIBuildwheels 2.16.5
RUrlus Jan 31, 2024
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
24 changes: 24 additions & 0 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
# https://clang.llvm.org/docs/ClangFormatStyleOptions.html
# customized using https://zed0.co.uk/clang-format-configurator/
---
BasedOnStyle: 'Google'
ColumnLimit: 80
AlignOperands: true
AllowAllParametersOfDeclarationOnNextLine: true
AlignAfterOpenBracket: 'BlockIndent'
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
AlwaysBreakTemplateDeclarations: 'Yes'
BinPackParameters: false
BinPackArguments: false
BreakBeforeBinaryOperators: 'All'
FixNamespaceComments: true
IndentWidth: 4
AccessModifierOffset: -3
IncludeBlocks: 'Preserve'
PointerAlignment: 'Left'
Standard: 'Cpp11'
UseTab: 'Never'
5 changes: 5 additions & 0 deletions .clang-tidy
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
Checks: 'clang-diagnostic-*,clang-analyzer-*,openmp-*,performance-*,cppcoreguidelines-*,modernize-*,-modernize-use-trailing-return-type,-cppcoreguidelines-pro-bounds-pointer-arithmetic, -cppcoreguidelines-pro-type-member-init, -cppcoreguidelines-avoid-magic-numbers, -modernize-avoid-c-arrays, -cppcoreguidelines-avoid-c-arrays, -hicpp-avoid-c-arrays, -cppcoreguidelines-init-variables'
WarningsAsErrors: 'true'
HeaderFilterRegex: ''
AnalyzeTemporaryDtors: false
3 changes: 3 additions & 0 deletions .clangd
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
CompileFlags:
Add: [-Wall -Wextra -Wunused-variable -Wunused-const-variable]
Remove: [-fopenmp]
76 changes: 76 additions & 0 deletions .github/workflows/nonvendored_wheels.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
name: Non-vendored Build and Publish

on:
workflow_dispatch:
pull_request:
push:
branches:
- main
release:
types:
- published

jobs:
build_sdist:
name: Build SDist
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: true

- name: Build SDist
run: pipx run build --sdist

- name: Check metadata
run: pipx run twine check dist/*

- uses: actions/upload-artifact@v4
with:
name: artifact-sdist
path: dist/*.tar.gz


build_wheels:
name: Wheels on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]

steps:
- uses: actions/checkout@v4
with:
submodules: true

- uses: actions/setup-python@v3

- name: Install cibuildwheel
run: python -m pip install cibuildwheel==2.16.5

- name: Build wheels
run: python -m cibuildwheel --output-dir wheelhouse

- name: Verify clean directory
run: git diff --exit-code
shell: bash

- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: artifact-${{ matrix.os }}
path: wheelhouse/*.whl


upload_all:
name: Upload if release
needs: [build_wheels, build_sdist]
runs-on: ubuntu-latest

steps:
- uses: actions/download-artifact@v4
with:
pattern: artifact-*
merge-multiple: true
path: dist
42 changes: 20 additions & 22 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,36 +1,34 @@
name: Run tests
name: Build & Test

on:
workflow_dispatch:
pull_request:
push:
branches:
- master

jobs:
test:
runs-on: ${{ matrix.os }}
build:
name: Build
runs-on: ${{ matrix.platform }}
strategy:
fail-fast: false
matrix:
python-version: [3.6, 3.7, 3.8, 3.9, 3.11]
# For the OS, ubuntu-latest is not compatible with Python 3.6 anymore,
# so we can use ubuntu-20.04 that is compatible with 3.6 and 3.11
# see: https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json
os: [ubuntu-20.04, windows-latest]
platform: [windows-latest, macos-latest, ubuntu-latest]
python-version: ["3.8", "3.12"]

steps:
- uses: actions/checkout@v2

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
- uses: actions/checkout@v4

- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}
- name: Install dev-package

- name: Build and install
run: |
python -m pip install --upgrade pip
pip install -v -e .
- name: Run tests
pip install pip --upgrade
pip install ".[test]" --verbose

- name: Test
run: |
pip install pytest
pip install pandas
pytest -ra --capture=no --showlocals
cd tests
pytest -vv
32 changes: 32 additions & 0 deletions .github/workflows/test_all_python.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Build & Test CPython

on:
workflow_dispatch:
pull_request:

jobs:
build:
name: Build
runs-on: ${{ matrix.platform }}
strategy:
fail-fast: false
matrix:
platform: [windows-latest, macos-latest, ubuntu-latest]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]

steps:
- uses: actions/checkout@v4

- uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- name: Build and install
run: |
pip install pip --upgrade
pip install ".[test]" --verbose

- name: Test
run: |
cd tests
pytest -vv
Loading
Loading