2014-07-17 15:31:35 +00:00
|
|
|
#
|
|
|
|
|
# spec file for package python-numexpr
|
|
|
|
|
#
|
2025-08-27 04:11:40 +00:00
|
|
|
# Copyright (c) 2025 SUSE LLC and contributors
|
2014-07-17 15:31:35 +00:00
|
|
|
#
|
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
|
# published by the Open Source Initiative.
|
2015-05-15 05:43:52 +00:00
|
|
|
|
2018-12-23 04:00:53 +00:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2014-07-17 15:31:35 +00:00
|
|
|
#
|
|
|
|
|
|
2015-05-15 05:43:52 +00:00
|
|
|
|
2023-12-18 09:24:49 +00:00
|
|
|
%{?sle15_python_module_pythons}
|
2016-02-03 09:19:43 +00:00
|
|
|
Name: python-numexpr
|
- update to 2.14.1:
* Rolled back static typing support to ensure compatibiity with
NumPy 1.26.
* Added CI tests for NumPy 1.26
* Numerical stability for overflow has been improved for tan /
tanh to handle possible overflows for complex numbers.
* Static typing support has been added, making NumExpr
compatible with static type checkers like mypy and pyright.
Thanks to Joren Hammudoglu (@jorenham) for the work.
* Patch to maximum/minimum functions in order to match NumPy
NaN handling
* Patch to convert '+'->'|' and '*'->'&' for booleans
* New functionality has been added:
* Bitwise operators (and, or, not, xor): &, |, ~, ^
* New binary arithmetic operator for floor division: //
* New functions: signbit, hypot, copysign, nextafter, maximum,
minimum, log2, trunc, round and sign.
* Also enables integer outputs for integer inputs for abs,
copy, ones_like, sign and round.
* New wheels for Python 3.14 and 3.14t are provided.
* Added complex counterparts for isnan/isfinite/isinf
functions. Thanks to Luke Shaw.
* Updated documentation for the new functions and instructions
for adding new functions to the virtual machine. Thanks to
Luke Shaw.
* Fixed MKL support; it was broken in 2.12.0.
* Added isnan/isfinite/isinf functions.
OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-numexpr?expand=0&rev=47
2025-11-17 21:48:39 +00:00
|
|
|
Version: 2.14.1
|
2014-07-17 15:31:35 +00:00
|
|
|
Release: 0
|
2017-10-05 09:58:44 +00:00
|
|
|
Summary: Numerical expression evaluator for NumPy
|
2014-07-17 15:31:35 +00:00
|
|
|
License: MIT
|
2018-09-03 09:06:05 +00:00
|
|
|
URL: https://github.com/pydata/numexpr/
|
2017-05-03 13:55:01 +00:00
|
|
|
Source: https://files.pythonhosted.org/packages/source/n/numexpr/numexpr-%{version}.tar.gz
|
2025-08-27 04:11:40 +00:00
|
|
|
BuildRequires: %{python_module devel >= 3.10}
|
|
|
|
|
BuildRequires: %{python_module numpy-devel >= 2.0}
|
2023-09-05 08:00:57 +00:00
|
|
|
BuildRequires: %{python_module pip}
|
2024-02-06 09:35:09 +00:00
|
|
|
BuildRequires: %{python_module setuptools}
|
2023-09-05 08:00:57 +00:00
|
|
|
BuildRequires: %{python_module wheel}
|
2017-09-28 10:34:50 +00:00
|
|
|
BuildRequires: fdupes
|
|
|
|
|
BuildRequires: gcc-c++
|
|
|
|
|
BuildRequires: python-rpm-macros
|
2025-08-27 04:11:40 +00:00
|
|
|
Requires: python-numpy >= 2.0
|
2017-05-03 13:55:01 +00:00
|
|
|
%python_subpackages
|
2014-07-17 15:31:35 +00:00
|
|
|
|
|
|
|
|
%description
|
2017-10-05 09:58:44 +00:00
|
|
|
Numexpr is a numerical expression evaluator for NumPy. It is a C++
|
|
|
|
|
module. With it, expressions that operate on arrays (like "3*a+4*b")
|
|
|
|
|
can be accelerated and use less memory than doing the same
|
|
|
|
|
calculation in Python.
|
2014-07-17 15:31:35 +00:00
|
|
|
|
|
|
|
|
%prep
|
2024-04-23 14:04:37 +00:00
|
|
|
%autosetup -p1 -n numexpr-%{version}
|
2018-12-23 04:00:53 +00:00
|
|
|
# wrong-file-end-of-line-encoding
|
|
|
|
|
sed -i 's/\r$//' ANNOUNCE.rst AUTHORS.txt README.rst RELEASE_NOTES.rst site.cfg.example
|
2015-05-15 05:43:52 +00:00
|
|
|
# remove unwanted shebang
|
|
|
|
|
sed -i '/^#!/ d' numexpr/cpuinfo.py
|
2014-07-17 15:31:35 +00:00
|
|
|
|
|
|
|
|
%build
|
2017-05-03 13:55:01 +00:00
|
|
|
export CFLAGS="%{optflags} -fno-strict-aliasing"
|
2023-09-05 08:00:57 +00:00
|
|
|
%pyproject_wheel
|
2014-07-17 15:31:35 +00:00
|
|
|
|
|
|
|
|
%install
|
2023-09-05 08:00:57 +00:00
|
|
|
%pyproject_install
|
2024-11-12 11:40:48 +00:00
|
|
|
# Remove devel files
|
|
|
|
|
%{python_expand #
|
|
|
|
|
find %{buildroot}%{$python_sitearch} -name *.hpp -type f -delete
|
|
|
|
|
find %{buildroot}%{$python_sitearch} -name *.cpp -type f -delete
|
|
|
|
|
}
|
2017-05-03 13:55:01 +00:00
|
|
|
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
2014-07-17 15:31:35 +00:00
|
|
|
|
2018-12-23 04:00:53 +00:00
|
|
|
%check
|
|
|
|
|
mkdir tester
|
|
|
|
|
pushd tester
|
2024-11-12 11:40:48 +00:00
|
|
|
|
2018-12-23 04:00:53 +00:00
|
|
|
%{python_expand export PYTHONPATH=%{buildroot}%{$python_sitearch}
|
|
|
|
|
$python -B -c "import sys;import numexpr;sys.exit(0 if numexpr.test().wasSuccessful() else 1)"
|
|
|
|
|
}
|
|
|
|
|
popd
|
|
|
|
|
|
2017-05-03 13:55:01 +00:00
|
|
|
%files %{python_files}
|
2018-08-07 07:44:18 +00:00
|
|
|
%doc ANNOUNCE.rst AUTHORS.txt README.rst RELEASE_NOTES.rst site.cfg.example
|
|
|
|
|
%license LICENSE.txt
|
2023-09-05 08:00:57 +00:00
|
|
|
%{python_sitearch}/numexpr
|
|
|
|
|
%{python_sitearch}/numexpr-%{version}.dist-info
|
2014-07-17 15:31:35 +00:00
|
|
|
|
|
|
|
|
%changelog
|