Compare commits
1 commit
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
63680c2486 |
3 changed files with 54 additions and 10 deletions
43
apache-commons-math-3.4.1-RHBZ1402145.patch
Normal file
43
apache-commons-math-3.4.1-RHBZ1402145.patch
Normal file
|
|
@ -0,0 +1,43 @@
|
|||
X-Git-Url: https://git1-us-west.apache.org/repos/asf?p=commons-math.git;a=blobdiff_plain;f=src%2Ftest%2Fjava%2Forg%2Fapache%2Fcommons%2Fmath3%2Fml%2Fneuralnet%2Fsofm%2FKohonenUpdateActionTest.java;h=b209d56b8651eb6e7bbfca10ad9bdb1802fb24f3;hp=334a5a8ebbbd011aa7d10bebbc5478df5f82becc;hb=a9006aa;hpb=838788fd6302d6cc91e1743144e0f14b71e4812e
|
||||
|
||||
diff --git a/src/test/java/org/apache/commons/math3/ml/neuralnet/sofm/KohonenUpdateActionTest.java b/src/test/java/org/apache/commons/math3/ml/neuralnet/sofm/KohonenUpdateActionTest.java
|
||||
index 334a5a8..b209d56 100644
|
||||
--- a/src/test/java/org/apache/commons/math3/ml/neuralnet/sofm/KohonenUpdateActionTest.java
|
||||
+++ b/src/test/java/org/apache/commons/math3/ml/neuralnet/sofm/KohonenUpdateActionTest.java
|
||||
@@ -17,18 +17,19 @@
|
||||
|
||||
package org.apache.commons.math3.ml.neuralnet.sofm;
|
||||
|
||||
-import org.apache.commons.math3.ml.neuralnet.Neuron;
|
||||
-import org.apache.commons.math3.ml.neuralnet.Network;
|
||||
-import org.apache.commons.math3.ml.neuralnet.MapUtils;
|
||||
-import org.apache.commons.math3.ml.neuralnet.UpdateAction;
|
||||
-import org.apache.commons.math3.ml.neuralnet.OffsetFeatureInitializer;
|
||||
-import org.apache.commons.math3.ml.neuralnet.FeatureInitializer;
|
||||
-import org.apache.commons.math3.ml.neuralnet.FeatureInitializerFactory;
|
||||
import org.apache.commons.math3.ml.distance.DistanceMeasure;
|
||||
import org.apache.commons.math3.ml.distance.EuclideanDistance;
|
||||
+import org.apache.commons.math3.ml.neuralnet.FeatureInitializer;
|
||||
+import org.apache.commons.math3.ml.neuralnet.FeatureInitializerFactory;
|
||||
+import org.apache.commons.math3.ml.neuralnet.MapUtils;
|
||||
+import org.apache.commons.math3.ml.neuralnet.Network;
|
||||
+import org.apache.commons.math3.ml.neuralnet.Neuron;
|
||||
+import org.apache.commons.math3.ml.neuralnet.OffsetFeatureInitializer;
|
||||
+import org.apache.commons.math3.ml.neuralnet.UpdateAction;
|
||||
import org.apache.commons.math3.ml.neuralnet.oned.NeuronString;
|
||||
-import org.junit.Test;
|
||||
+import org.apache.commons.math3.util.Precision;
|
||||
import org.junit.Assert;
|
||||
+import org.junit.Test;
|
||||
|
||||
/**
|
||||
* Tests for {@link KohonenUpdateAction} class.
|
||||
@@ -82,7 +83,7 @@ public class KohonenUpdateActionTest {
|
||||
|
||||
Assert.assertEquals(bestBefore, bestAfter);
|
||||
// Distance is now zero.
|
||||
- Assert.assertEquals(0, dist.compute(bestAfter.getFeatures(), features), 0d);
|
||||
+ Assert.assertEquals(0, dist.compute(bestAfter.getFeatures(), features), Precision.EPSILON);
|
||||
|
||||
for (int i = 0; i < netSize; i++) {
|
||||
// All distances have decreased.
|
||||
|
|
@ -2,20 +2,22 @@
|
|||
|
||||
Name: apache-commons-math
|
||||
Version: 3.4.1
|
||||
Release: 3%{?dist}
|
||||
Release: 4%{?dist}
|
||||
Summary: Java library of lightweight mathematics and statistics components
|
||||
Group: Development/Libraries
|
||||
License: ASL 1.1 and ASL 2.0 and BSD
|
||||
URL: http://commons.apache.org/math/
|
||||
Source0: http://www.apache.org/dist/commons/math/source/%{short_name}-%{version}-src.tar.gz
|
||||
# Fix random build self-test failures reported on RHBZ #1402145 (see
|
||||
# https://git1-us-west.apache.org/repos/asf?p=commons-math.git;a=commit;h=a9006aa)
|
||||
Patch1: %{name}-3.4.1-RHBZ1402145.patch
|
||||
|
||||
BuildRequires: java-devel >= 1:1.6.0
|
||||
BuildRequires: jpackage-utils
|
||||
BuildRequires: maven-local
|
||||
|
||||
%if 0%{?fedora} >= 21
|
||||
BuildRequires: mvn(org.apache.commons:commons-parent:pom:)
|
||||
BuildRequires: mvn(org.jacoco:jacoco-maven-plugin) >= 0.7.0
|
||||
%endif
|
||||
Requires: jpackage-utils
|
||||
BuildArch: noarch
|
||||
|
||||
|
|
@ -34,17 +36,12 @@ This package contains the API documentation for %{name}.
|
|||
|
||||
|
||||
%prep
|
||||
%setup -q -n %{short_name}-%{version}-src
|
||||
%autosetup -n %{short_name}-%{version}-src -p1
|
||||
|
||||
# Compatibility links
|
||||
%mvn_alias "org.apache.commons:%{short_name}" "%{short_name}:%{short_name}"
|
||||
%mvn_file :%{short_name} %{short_name} %{name}
|
||||
|
||||
# Disable Jacoco Maven plugin for Fedora releases having jacoco < 0.7.0
|
||||
%if 0%{?fedora} < 21
|
||||
rm src/site/resources/profile.jacoco
|
||||
%endif
|
||||
|
||||
# Disable maven-jgit-buildnumber-plugin plugin (not available in Fedora)
|
||||
%pom_remove_plugin ru.concerteza.buildnumber:maven-jgit-buildnumber-plugin
|
||||
|
||||
|
|
@ -66,6 +63,10 @@ rm src/site/resources/profile.jacoco
|
|||
|
||||
|
||||
%changelog
|
||||
* Fri Dec 16 2016 Mohamed El Morabity <melmorabity@fedoraproject.org> - 3.4.1-4
|
||||
- Fix RHBZ #1402145
|
||||
- Spec cleanup
|
||||
|
||||
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 3.4.1-3
|
||||
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
|
||||
|
||||
|
|
|
|||
2
sources
2
sources
|
|
@ -1 +1 @@
|
|||
01daa3eedd61cfe3315fb0417fc8ac2e commons-math3-3.4.1-src.tar.gz
|
||||
SHA512 (commons-math3-3.4.1-src.tar.gz) = 21c926870ebc40e9594750545299005c53782efac4e411db773253db95cf3e6fbf770da1e52db2b88676310d1ecffc9b5fd28c03b2acbfe126f87b4f67718866
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue