Skip to content

Commit 9509b32

Browse files
committed
Fixes for windows
1 parent deb2a39 commit 9509b32

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

Diff for: qml/neurons/OldNeuron.qml

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ Node {
1313
property alias voltage: engine.voltage
1414
property real acceleration: 0.0
1515
property real speed: 0.0
16-
property alias cm: engine.cm
16+
// property alias cm: engine.cm
1717
// property var outputNeurons: []
1818
property point connectionPoint: Qt.point(x + width / 2, y + height / 2)
1919
property alias synapticConductance: engine.synapticConductance

Diff for: src/engine/receptivefield.cpp

+3-1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@
22

33
#include <cmath>
44

5+
const static long double pi = 3.141592653589793238462643383279502884L;
6+
57
ReceptiveField::ReceptiveField()
68
{
79
}
@@ -114,7 +116,7 @@ double ReceptiveField::gaborField(int idx, int idy)
114116
double x = idx * cos(theta) + idy * sin(theta);
115117
double y = -idx * sin(theta) + idy * cos(theta);
116118

117-
double prefactor = 1.0/(2.* M_PI * sigmaX * sigmaY);
119+
double prefactor = 1.0/(2.* pi * sigmaX * sigmaY);
118120
double expFactor = exp(-x*x/(2.* sigmaX * sigmaX) - y*y/(2. * sigmaY * sigmaY));
119121
double cosFactor = cos(k * x - phi);
120122
return prefactor * expFactor * cosFactor;

0 commit comments

Comments
 (0)