17
0
Files
python-pomegranate/python-pomegranate.spec

88 lines
2.8 KiB
RPMSpec
Raw Permalink Normal View History

#
# spec file for package python-pomegranate
#
# Copyright (c) 2021 SUSE LLC
#
# 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.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define skip_python36 1
Name: python-pomegranate
Accepting request 761206 from home:TheBlackCat:branches:devel:languages:python:numeric - Update to Version 0.12.0 + Highlights * MarkovNetwork models have been added in and include both inference and structure learning. * Support for Python 2 has been depricated. * Markov network, data generator, and callback tutorials have been added in * A robust `from_json` method has been added in to __init__.py that can deserialize JSONs from any pomegranate model. + MarkovNetwork * MarkovNetwork models have been added in as a new probabilistic model. * Loopy belief propagation inference has been added in using the FactorGraph backend * Structure learning has been added in using Chow-Liu trees + BayesianNetwork * Chow-Liu tree building has been sped up slightly, courtesy of @alexhenrie * Chow-Liu tree building was further sped up by almost an order of magnitude * Constraint Graphs no longer fail when passing in graphs with self loops, courtesy of @alexhenrie + BayesClassifier * Updated the `from_samples` method to accept BayesianNetwork as an emission. This will build one Bayesian network for each class and use them as the emissions. + Distributions * Added a warning to DiscreteDistribution when the user passes in an empty dictionary. * Fixed the sampling procedure for JointProbabilityTables. * GammaDistributions should have their shape issue resolved * The documentation for BetaDistributions has been updated to specify that it is a Beta-Bernoulli distribution. + io * New file added, io.py, that contains data generators that can be operated on * Added DataGenerator, DataFrameGenerator, and a BaseGenerator class to inherit from + HiddenMarkovModel * Added RandomState parameter to `from_samples` to account for randomness when building discrete models. + Misc * Unneccessary calls to memset have been removed, courtesy of @alexhenrie * Checking for missing values has been slightly refactored to be cleaner, courtesy of @mareksmid-lucid * Include the LICENSE file in MANIFEST.in and simplify a bit, courtesy of @toddrme2178 * Added in a robust from_json method that can be used to deseralize a JSON for any pomegranate model. + docs * Added io.rst to briefly describe data generators * Added MarkovNetwork.rst to describe Markov networks * Added links to tutorials that did not have tutorials linked to them. + Tutorials * Added in a tutorial notebook for Markov networks * Added in a tutorial notebook for data generators * Added in a tutorial notebook for callbacks + CI * Removed unit tests for Py2.7 from AppVeyor and Travis * Added unit tests for Py3.8 to AppVeyor and Travis - Dropped python2 support OBS-URL: https://build.opensuse.org/request/show/761206 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python:numeric/python-pomegranate?expand=0&rev=3
2020-01-06 15:59:56 +00:00
Version: 0.12.0
Release: 0
Summary: A graphical models library for Python
License: MIT
URL: https://github.com/jmschrei/pomegranate
Source: https://github.com/jmschrei/pomegranate/archive/v%{version}.tar.gz#/pomegranate-%{version}.tar.gz
BuildRequires: %{python_module Cython >= 0.22.1}
BuildRequires: %{python_module devel}
BuildRequires: %{python_module numpy >= 1.8.0}
BuildRequires: %{python_module numpy-devel >= 1.8.0}
BuildRequires: %{python_module scipy >= 0.17.0}
BuildRequires: %{python_module setuptools}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-PyYAML
Requires: python-joblib >= 0.9.0b4
Requires: python-networkx >= 2.0
Requires: python-numpy >= 1.8.0
Requires: python-scipy >= 0.17.0
# SECTION test requirements
BuildRequires: %{python_module PyYAML}
BuildRequires: %{python_module joblib >= 0.9.0b4}
BuildRequires: %{python_module networkx >= 2.0}
BuildRequires: %{python_module numpy >= 1.8.0}
BuildRequires: %{python_module scipy >= 0.17.0}
# /SECTION
%python_subpackages
%description
Pomegranate is a graphical models library for Python, implemented in Cython for speed.
%package devel
Summary: Development files for %{name}
Requires: python-pomegranate = %{version}
%description devel
Pomegranate is a graphical models library for Python, implemented in Cython for speed.
This package provides development files needed to run software that depends on
Pomegranate.
%prep
%setup -q -n pomegranate-%{version}
%build
export CFLAGS="%{optflags}"
%python_build
%install
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitearch}
%files %{python_files}
%doc README.md
%license LICENSE
%{python_sitearch}/pomegranate/
%{python_sitearch}/pomegranate-%{version}-py*.egg-info
%exclude %{python_sitearch}/pomegranate/*.c
%exclude %{python_sitearch}/pomegranate/*/*.c
%files %{python_files devel}
%license LICENSE
%{python_sitearch}/pomegranate/*.c
%{python_sitearch}/pomegranate/*/*.c
%changelog