Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
bob
bob.learn.mlp
Commits
60143eb6
Commit
60143eb6
authored
Apr 21, 2015
by
Manuel Günther
Browse files
Disabled __repr__ method to make the tests pass again (see
#5
)
parent
875236e0
Changes
1
Hide whitespace changes
Inline
Side-by-side
bob/learn/mlp/machine.cpp
View file @
60143eb6
...
...
@@ -696,7 +696,7 @@ PyObject* PyBobLearnMLPMachine_Repr(PyBobLearnMLPMachineObject* self) {
/**
* Expected output:
*
* <bob.learn.
linear
.MLP float64@(3, 5, 2) [hidden: f(z) = tanh(z), out: f(z) = * tanh(z)]>
* <bob.learn.
mlp
.MLP float64@(3, 5, 2) [hidden: f(z) = tanh(z), out: f(z) = * tanh(z)]>
*/
BOB_TRY
...
...
@@ -719,7 +719,7 @@ BOB_TRY
hidden
.
c_str
());
}
else
{
retval
=
PyUnicode_FromFormat
(
"<%s %s@%s [
ac
t: %s]>"
,
retval
=
PyUnicode_FromFormat
(
"<%s %s@%s [
hidden: %s, ou
t: %s]>"
,
Py_TYPE
(
self
)
->
tp_name
,
dtype_str
.
get
(),
shape_str
.
get
(),
hidden
.
c_str
(),
output
.
c_str
());
}
...
...
@@ -1076,13 +1076,13 @@ PyTypeObject PyBobLearnMLPMachine_Type = {
0
,
/* tp_getattr */
0
,
/* tp_setattr */
0
,
/* tp_compare */
(
reprfunc
)
PyBobLearnMLPMachine_Repr
,
/* tp_repr */
0
,
//
(reprfunc)PyBobLearnMLPMachine_Repr, /* tp_repr */
0
,
/* tp_as_number */
0
,
/* tp_as_sequence */
0
,
/* tp_as_mapping */
0
,
/* tp_hash */
(
ternaryfunc
)
PyBobLearnMLPMachine_forward
,
/* tp_call */
(
reprfunc
)
PyBobLearnMLPMachine_Repr
,
/* tp_str */
0
,
//
(reprfunc)PyBobLearnMLPMachine_Repr, /* tp_str */
0
,
/* tp_getattro */
0
,
/* tp_setattro */
0
,
/* tp_as_buffer */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment