Skip to content

Commit

Permalink
Fix small codestyle problems
Browse files Browse the repository at this point in the history
  • Loading branch information
Milan Jelisavcic committed Jul 29, 2017
1 parent 1f66ab2 commit 0e6f5b4
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 13 deletions.
19 changes: 9 additions & 10 deletions cpp/revolve/gazebo/brain/NeuralNetwork.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -17,18 +17,17 @@
*
*/

#include "NeuralNetwork.h"
#include "../motors/Motor.h"
#include "../sensors/Sensor.h"

#include <iostream>
#include <algorithm>
#include <stdexcept>
#include <cmath>
#include <cstdlib>
#include <map>
#include <string>
#include <iostream>
#include <sstream>
#include <cmath>
#include <stdexcept>

#include "../motors/Motor.h"
#include "../sensors/Sensor.h"

#include "NeuralNetwork.h"

namespace gz = gazebo;

Expand All @@ -55,7 +54,7 @@ NeuralNetwork::NeuralNetwork(std::string modelName,

// Listen to network modification requests
alterSub_ = node_->Subscribe("~/"+modelName+"/modify_neural_network",
&NeuralNetwork::modify, this);
&NeuralNetwork::modify, this);

// Initialize weights, input and states to zero by default
memset(inputWeights_, 0, sizeof(inputWeights_));
Expand Down
5 changes: 4 additions & 1 deletion cpp/revolve/gazebo/sensors/VirtualSensor.h
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,10 @@ namespace gazebo {

class VirtualSensor {
public:
VirtualSensor(::gazebo::physics::ModelPtr model, std::string partId, std::string sensorId, unsigned int inputs);
VirtualSensor(::gazebo::physics::ModelPtr model,
std::string partId,
std::string sensorId,
unsigned int inputs);
virtual ~VirtualSensor();

/**
Expand Down
2 changes: 1 addition & 1 deletion revolve/angle/generate.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
generated. The interface of this body is then fed to the neural net
generator resulting in a neural network.
"""
from ..generate import BodyGenerator
from ..generate import NeuralNetworkGenerator, BodyGenerator
from .representation import Tree


Expand Down
2 changes: 1 addition & 1 deletion revolve/angle/representation.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import copy
from ..spec.msgs import Robot, BodyPart, NeuralNetwork, Body
from ..spec.msgs import Robot, BodyPart, Neuron, NeuralNetwork, Body
from ..spec import BodyImplementation


Expand Down

0 comments on commit 0e6f5b4

Please sign in to comment.