
Product
Introducing Rust Support in Socket
Socket now supports Rust and Cargo, offering package search for all users and experimental SBOM generation for enterprise projects.
About An advanced Python library implementing Kadane’s Algorithm with support for 1D & 2D arrays, visualization, subarray constraints, and test coverage. Perfect for data analysis, time-series problems, and algorithm enthusiasts.
kadane-adv is a Python package that extends the classic Kadane’s Algorithm to support advanced use cases in 1D and 2D data analysis. Designed for performance and simplicity, it provides efficient tools to identify optimal subarrays and submatrices across diverse datasets—time series, financial data, sensor logs, or image matrices.
It is an essential utility for data analysts, researchers, and machine learning developers seeking meaningful patterns in structured data.
🔹 1D Maximum Subarray Detection
Find the subarray with the maximum sum in linear time.
🔹 2D Maximum Submatrix Detection
Extend Kadane’s algorithm to rectangular regions in 2D matrices.
🔹 Constrained Optimization
Support for constraints such as minimum subarray length.
🔹 Built-in Visualization
Visual representation of the detected optimal regions.
🔹 Integration with NumPy & Pandas
Supports direct use of NumPy arrays and Pandas DataFrames.
🔹 Real-world Applications
Use it in financial trend analysis, signal processing, sensor logs, and image matrix optimization.
You can install the library using pip:
pip install kadane-adv
cd kadane-adv
python setup.py install
numpy
— for matrix and array operationsmatplotlib
— for visualizationspandas
— for seamless DataFrame integrationExact versions can be found in the
requirements.txt
file.
Licensed under the MIT License.
See the LICENSE
file for full text.
help()
function or your IDE's documentation viewerWhile classic Kadane’s algorithm finds the maximum sum subarray in 1D, kadane-adv extends this by adding:
help(kadane_adv.function_name)
in PythonThe project evolves with real-world needs in:
Your suggestions and use-cases are welcome!
We welcome contributions in all forms! You can help by:
Let’s make this tool better — together!
FAQs
About An advanced Python library implementing Kadane’s Algorithm with support for 1D & 2D arrays, visualization, subarray constraints, and test coverage. Perfect for data analysis, time-series problems, and algorithm enthusiasts.
We found that kadane-adv demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Socket now supports Rust and Cargo, offering package search for all users and experimental SBOM generation for enterprise projects.
Product
Socket’s precomputed reachability slashes false positives by flagging up to 80% of vulnerabilities as irrelevant, with no setup and instant results.
Product
Socket is launching experimental protection for Chrome extensions, scanning for malware and risky permissions to prevent silent supply chain attacks.