Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix/controlmechanism/assign as controller #619

Merged
merged 80 commits into from
Jan 16, 2018
Merged
Changes from all commits
Commits
Show all changes
80 commits
Select commit Hold shift + click to select a range
3276e28
• System
jdcpni Nov 30, 2017
6908d7f
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Nov 30, 2017
461e18f
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 4, 2017
bd5f9a0
• Log
jdcpni Dec 5, 2017
04ffdac
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 5, 2017
2d6409b
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 5, 2017
7b7e277
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 7, 2017
cda732e
-
jdcpni Dec 7, 2017
9d204af
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 10, 2017
a6449c1
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 10, 2017
5603fa6
-
jdcpni Dec 10, 2017
21332d7
-
jdcpni Dec 10, 2017
335ab58
-
jdcpni Dec 10, 2017
51c0aed
-
jdcpni Dec 10, 2017
ab5144b
-
jdcpni Dec 10, 2017
6d58251
-
jdcpni Dec 10, 2017
5516f6d
-
jdcpni Dec 10, 2017
1dec9aa
-
jdcpni Dec 10, 2017
3e4766d
-
jdcpni Dec 10, 2017
e1ffdec
-
jdcpni Dec 10, 2017
0eec811
-
jdcpni Dec 10, 2017
17b487c
-
jdcpni Dec 10, 2017
3f438f5
Merge branch 'feat/Log/clean_up' into devel
jdcpni Dec 10, 2017
0561216
-
jdcpni Dec 10, 2017
c76a3a8
• Log
jdcpni Dec 10, 2017
43f9a0d
• Log
jdcpni Dec 10, 2017
17eaa3a
-
jdcpni Dec 11, 2017
f495751
-
jdcpni Dec 11, 2017
bb4fecd
-
jdcpni Dec 11, 2017
9579899
-
jdcpni Dec 11, 2017
aa679dd
-
jdcpni Dec 11, 2017
d7024ae
-
jdcpni Dec 11, 2017
73a8013
-
jdcpni Dec 11, 2017
6416865
• Log
jdcpni Dec 11, 2017
e200f88
• Log
jdcpni Dec 11, 2017
e5a3881
• Log
jdcpni Dec 11, 2017
5065c1d
• Log
jdcpni Dec 11, 2017
36c0988
• Log
jdcpni Dec 11, 2017
fe14d1e
• Log
jdcpni Dec 11, 2017
3a29540
• Log
jdcpni Dec 11, 2017
de216a8
Merge branch 'feat/Log/add_entry' into devel
jdcpni Dec 11, 2017
4dacd4d
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 11, 2017
5f043a0
-
jdcpni Dec 12, 2017
2d6b0a2
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 12, 2017
d2e5167
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 12, 2017
7baddea
• Component
jdcpni Dec 12, 2017
5e959fb
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 13, 2017
979a9ea
• Log
jdcpni Dec 13, 2017
5a5d15d
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 13, 2017
47cd066
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 13, 2017
7bc2742
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 14, 2017
7e0c5d3
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 14, 2017
77e1931
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 15, 2017
8efca34
-
jdcpni Dec 15, 2017
00bd2f6
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 15, 2017
b6ad64c
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 18, 2017
1f51655
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 18, 2017
2033960
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 19, 2017
a81835c
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 21, 2017
5e18235
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 21, 2017
35b1c55
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Dec 23, 2017
189dc67
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Jan 4, 2018
8920f94
Merge branch 'devel' of https://github.com/PrincetonUniversity/PsyNeu…
jdcpni Jan 11, 2018
470a15e
-
jdcpni Jan 11, 2018
7f1bd4a
• ObjectiveMechanism
jdcpni Jan 11, 2018
2175140
• System
jdcpni Jan 11, 2018
f1523c4
-
jdcpni Jan 11, 2018
2e11905
• ControlMechanism
jdcpni Jan 11, 2018
1d8736d
• ControlMechanism
jdcpni Jan 11, 2018
2724a7c
• ControlMechanism
jdcpni Jan 12, 2018
792295d
• System
jdcpni Jan 14, 2018
1e70000
• System
jdcpni Jan 14, 2018
75225fc
• System
jdcpni Jan 16, 2018
92475fd
-
jdcpni Jan 16, 2018
1808653
-
jdcpni Jan 16, 2018
d7640b5
-
jdcpni Jan 16, 2018
746cc36
Merge branch 'devel' into fix/controlmechanism/assign_as_controller
jdcpni Jan 16, 2018
4a0590a
• Function
jdcpni Jan 16, 2018
bfc6389
Merge branches 'devel' and 'fix/controlmechanism/assign_as_controller…
jdcpni Jan 16, 2018
f4b5e6e
• Function
jdcpni Jan 16, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions psyneulink/components/functions/function.py
Original file line number Diff line number Diff line change
Expand Up @@ -1567,15 +1567,15 @@ def _validate_params(self, request_set, target_set=None, context=None):
if any(c in context for c in {EXECUTING, LEARNING}):
if len(target_set[WEIGHTS]) != len(self.instance_defaults.variable):
raise FunctionError("Number of weights ({0}) is not equal to number of items in variable ({1})".
format(len(target_set[WEIGHTS]), len(self.instance_defaults.variable.shape)))
format(len(target_set[WEIGHTS]), len(self.instance_defaults.variable)))

if EXPONENTS in target_set and target_set[EXPONENTS] is not None:
self._validate_parameter_spec(target_set[EXPONENTS], EXPONENTS, numeric_only=True)
target_set[EXPONENTS] = np.atleast_2d(target_set[EXPONENTS]).reshape(-1, 1)
if any(c in context for c in {EXECUTING, LEARNING}):
if len(target_set[EXPONENTS]) != len(self.instance_defaults.variable):
raise FunctionError("Number of exponents ({0}) does not equal number of items in variable ({1})".
format(len(target_set[EXPONENTS]), len(self.instance_defaults.variable.shape)))
format(len(target_set[EXPONENTS]), len(self.instance_defaults.variable)))

if SCALE in target_set and target_set[SCALE] is not None:
scale = target_set[SCALE]
Expand All @@ -1593,7 +1593,8 @@ def _validate_params(self, request_set, target_set=None, context=None):
raise FunctionError("Scale is using Hadamard modulation "
"but its shape and/or size (shape: {}, size:{}) "
"do not match the variable being modulated (shape: {}, size: {})".
format(scale.shape, scale.size, self.instance_defaults.variable.shape, self.instance_defaults.variable.size))
format(scale.shape, scale.size, self.instance_defaults.variable.shape,
self.instance_defaults.variable.size))

if OFFSET in target_set and target_set[OFFSET] is not None:
offset = target_set[OFFSET]
Expand All @@ -1611,7 +1612,8 @@ def _validate_params(self, request_set, target_set=None, context=None):
raise FunctionError("Offset is using Hadamard modulation "
"but its shape and/or size (shape: {}, size:{}) "
"do not match the variable being modulated (shape: {}, size: {})".
format(offset.shape, offset.size, self.instance_defaults.variable.shape, self.instance_defaults.variable.size))
format(offset.shape, offset.size, self.instance_defaults.variable.shape,
self.instance_defaults.variable.size))

# if not operation:
# raise FunctionError("Operation param missing")
Expand Down