From 7feffc008b62c74925b037f4f362656bc1b8d392 Mon Sep 17 00:00:00 2001 From: CoprDistGit Date: Fri, 5 May 2023 09:16:43 +0000 Subject: automatic import of python-neurolab --- python-neurolab.spec | 186 +++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 186 insertions(+) create mode 100644 python-neurolab.spec (limited to 'python-neurolab.spec') diff --git a/python-neurolab.spec b/python-neurolab.spec new file mode 100644 index 0000000..2a62d03 --- /dev/null +++ b/python-neurolab.spec @@ -0,0 +1,186 @@ +%global _empty_manifest_terminate_build 0 +Name: python-neurolab +Version: 0.3.5 +Release: 1 +Summary: Simple and powerfull neural network library for python +License: LGPL-3 +URL: http://neurolab.googlecode.com +Source0: https://mirrors.nju.edu.cn/pypi/web/packages/46/fd/47a9a39158b461b6b862d64c0ad7f679b08ed6d316744299f0db89066342/neurolab-0.3.5.tar.gz +BuildArch: noarch + + +%description +Neurolab is a simple and powerful Neural Network Library for Python. +Contains based neural networks, train algorithms and flexible framework +to create and explore other neural network types. + + +:Features: + + - Pure python + numpy + - API like Neural Network Toolbox (NNT) from MATLAB + - Interface to use train algorithms form scipy.optimize + - Flexible network configurations and learning algorithms. You may change: train, error, initialization and activation functions + - Unlimited number of neural layers and number of neurons in layers + - Variety of supported types of Artificial Neural Network and learning algorithms + +:Example: + + >>> import numpy as np + >>> import neurolab as nl + >>> # Create train samples + >>> input = np.random.uniform(-0.5, 0.5, (10, 2)) + >>> target = (input[:, 0] + input[:, 1]).reshape(10, 1) + >>> # Create network with 2 inputs, 5 neurons in input layer and 1 in output layer + >>> net = nl.net.newff([[-0.5, 0.5], [-0.5, 0.5]], [5, 1]) + >>> # Train process + >>> err = net.train(input, target, show=15) + Epoch: 15; Error: 0.150308402918; + Epoch: 30; Error: 0.072265865089; + Epoch: 45; Error: 0.016931355131; + The goal of learning is reached + >>> # Test + >>> net.sim([[0.2, 0.1]]) # 0.2 + 0.1 + array([[ 0.28757596]]) + +:Links: + + - `Home Page `_ + - `PyPI Page `_ + - `Documentation `_ + - `Examples `_ + +%package -n python3-neurolab +Summary: Simple and powerfull neural network library for python +Provides: python-neurolab +BuildRequires: python3-devel +BuildRequires: python3-setuptools +BuildRequires: python3-pip +%description -n python3-neurolab +Neurolab is a simple and powerful Neural Network Library for Python. +Contains based neural networks, train algorithms and flexible framework +to create and explore other neural network types. + + +:Features: + + - Pure python + numpy + - API like Neural Network Toolbox (NNT) from MATLAB + - Interface to use train algorithms form scipy.optimize + - Flexible network configurations and learning algorithms. You may change: train, error, initialization and activation functions + - Unlimited number of neural layers and number of neurons in layers + - Variety of supported types of Artificial Neural Network and learning algorithms + +:Example: + + >>> import numpy as np + >>> import neurolab as nl + >>> # Create train samples + >>> input = np.random.uniform(-0.5, 0.5, (10, 2)) + >>> target = (input[:, 0] + input[:, 1]).reshape(10, 1) + >>> # Create network with 2 inputs, 5 neurons in input layer and 1 in output layer + >>> net = nl.net.newff([[-0.5, 0.5], [-0.5, 0.5]], [5, 1]) + >>> # Train process + >>> err = net.train(input, target, show=15) + Epoch: 15; Error: 0.150308402918; + Epoch: 30; Error: 0.072265865089; + Epoch: 45; Error: 0.016931355131; + The goal of learning is reached + >>> # Test + >>> net.sim([[0.2, 0.1]]) # 0.2 + 0.1 + array([[ 0.28757596]]) + +:Links: + + - `Home Page `_ + - `PyPI Page `_ + - `Documentation `_ + - `Examples `_ + +%package help +Summary: Development documents and examples for neurolab +Provides: python3-neurolab-doc +%description help +Neurolab is a simple and powerful Neural Network Library for Python. +Contains based neural networks, train algorithms and flexible framework +to create and explore other neural network types. + + +:Features: + + - Pure python + numpy + - API like Neural Network Toolbox (NNT) from MATLAB + - Interface to use train algorithms form scipy.optimize + - Flexible network configurations and learning algorithms. You may change: train, error, initialization and activation functions + - Unlimited number of neural layers and number of neurons in layers + - Variety of supported types of Artificial Neural Network and learning algorithms + +:Example: + + >>> import numpy as np + >>> import neurolab as nl + >>> # Create train samples + >>> input = np.random.uniform(-0.5, 0.5, (10, 2)) + >>> target = (input[:, 0] + input[:, 1]).reshape(10, 1) + >>> # Create network with 2 inputs, 5 neurons in input layer and 1 in output layer + >>> net = nl.net.newff([[-0.5, 0.5], [-0.5, 0.5]], [5, 1]) + >>> # Train process + >>> err = net.train(input, target, show=15) + Epoch: 15; Error: 0.150308402918; + Epoch: 30; Error: 0.072265865089; + Epoch: 45; Error: 0.016931355131; + The goal of learning is reached + >>> # Test + >>> net.sim([[0.2, 0.1]]) # 0.2 + 0.1 + array([[ 0.28757596]]) + +:Links: + + - `Home Page `_ + - `PyPI Page `_ + - `Documentation `_ + - `Examples `_ + +%prep +%autosetup -n neurolab-0.3.5 + +%build +%py3_build + +%install +%py3_install +install -d -m755 %{buildroot}/%{_pkgdocdir} +if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi +if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi +if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi +if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi +pushd %{buildroot} +if [ -d usr/lib ]; then + find usr/lib -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/lib64 ]; then + find usr/lib64 -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/bin ]; then + find usr/bin -type f -printf "/%h/%f\n" >> filelist.lst +fi +if [ -d usr/sbin ]; then + find usr/sbin -type f -printf "/%h/%f\n" >> filelist.lst +fi +touch doclist.lst +if [ -d usr/share/man ]; then + find usr/share/man -type f -printf "/%h/%f.gz\n" >> doclist.lst +fi +popd +mv %{buildroot}/filelist.lst . +mv %{buildroot}/doclist.lst . + +%files -n python3-neurolab -f filelist.lst +%dir %{python3_sitelib}/* + +%files help -f doclist.lst +%{_docdir}/* + +%changelog +* Fri May 05 2023 Python_Bot - 0.3.5-1 +- Package Spec generated -- cgit v1.2.3