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

Devel #2449

Merged
merged 151 commits into from
Jul 28, 2022
Merged

Devel #2449

merged 151 commits into from
Jul 28, 2022

Conversation

kmantel
Copy link
Collaborator

@kmantel kmantel commented Jul 25, 2022

No description provided.

jvesely and others added 30 commits March 28, 2022 10:36
…nction invocation

This eliminates the need for custom parsing of output port variables
for OCM.
This also eliminates one case of shape mismatches when constructing
output port inputs.

Signed-off-by: Jan Vesely <[email protected]>
…rameter

Split ControlMechanism tests from LCControlMechanism tests.

Signed-off-by: Jan Vesely <[email protected]>
…constructing output

Only allocate a new buffer if the type doesn't match the one provided by
the caller.

Signed-off-by: Jan Vesely <[email protected]>
The same behaviour is achieved by using Identity function.
The only difference is the shape of the `Mechanism.parameters.value`
intermediate result.

Signed-off-by: Jan Vesely <[email protected]>
…sm value and function output

ControlMechanism+DefaultAllocationFunction was the last users that
needed this workaround.

Signed-off-by: Jan Vesely <[email protected]>
ControlMechanism invokes its function just as other mechanisms.

Signed-off-by: Jan Vesely <[email protected]>
… pull requests (#2376)

When there are multiple tags pointing to the HEAD commit,
git describe returns the first in alphabetical order.
Use v0.0.0.0 to have a deterministic description
even if there is another tag pointing to the HEAD commit.

Fixes: 65967d9 ("ci: increase fetch depth and tags")

Signed-off-by: Jan Vesely <[email protected]>
…if possible (#2377)

Pass pointer to output storage to methods invoking mechanism functions.
Reuse the space for function output if possible and allocate new space if the type doesn't match.

This addresses most of the shape mismatch situations when in compiled mechanism execution.
Removing extra copies from the mechanism function output to its value parameter saves ~20GB  of private RW (10+10) traffic in the stability-flexibility model.

Make sure that all 'cuda' tests are also marked 'llvm'.
no longer needed due to shared_types and copy_iterable_with_shared
* • composition.py:
  moved calls to _update_controller to _complete_init_of_partially_initialized_nodes
  moved _update_controller to ocm._update_state_input_ports

• optimizationcontrolmechanism.py:
  added _update_state_input_ports [**still needed work**]

* • composition.py:
  moved calls to _update_controller to _complete_init_of_partially_initialized_nodes
  moved _update_controller to ocm._update_state_input_ports
  _instantiate_controller_shadow_projections [still needs to be implemented]

• optimizationcontrolmechanism.py:
  added _update_state_input_ports [**still needed work**]

* • composition.py
  added needs_update_controller

* -

* • composition.py:
  - implemented self.needs_update_controller
  - moved implementation of controlsignal projections
    from add_controller to _instantiate_control_projections
    that is called in _complete_init_of_partially_initialized_nodes

Note: still need to set  self.needs_update_controller to False
      after instantiating state_input_ports and projections to them

* -

* -

* -

* -

* -

* -

* -

* -

* • Passing all test_control tests except test_mode_based_num_estimates

* • Passing all test_control tests

* -

* • optimizationcontrolmechanism.py
  - _update_state_input_ports_for_controller: handle nested input nodes

* -

* • optimizationcontrolmechanism.py
  _update_state_input_ports_for_controller:  fixed bug with > 1 INPUT node in Composition

* • test_show_graph.py: passes all tests

* -

* • test_report.py:  passing all tests

* • Passes all tests!

* -

* -

* • composition.py: reorganize with #region and #enregions

* • composition.py: reorganize with #region and #enregions

* • controlmechanism.py, optimizationcontrolmechanism.py:
  - _instantiate_monitor_for_control_input_ports -> _parse_monitor_control_input_ports
  - refactored to support allow_probes option on ocm

* -

* -

* -

* • controlmechanism.py, optimizationcontrolmechanism.py:
  - _instantiate_monitor_for_control_input_ports -> _parse_monitor_control_input_ports
  - refactored to support allow_probes option on ocm

* • controlmechanism.py, optimizationcontrolmechanism.py:
  - _instantiate_monitor_for_control_input_ports -> _parse_monitor_control_input_ports
  - refactored to support allow_probes option on ocm

* -

* • composition.py:
  __init__: move controller to after add_nodes and add_linear_pathway

* -

* - test_control: only test_hanging_control_spec_outer_controller not passing

* -

* -

* -

* -

* -

* -

* • composition.py:
  _instantiate_control_projections:
     weird requirement for double-call to controller._instantiate_control_signal

* • test_paremtercomposition.py:
  restored parameter spec that causes crash ('threshold',Decision2)

* ª Attempt to fix problem with partially overlapping local and ocm control specs

- composition.py
  - _get_control_signals_for_composition:  (see 11/20/21)
      - added (but commented out change) to "if node.controller" to "if not node.controller"
      - changed append to extend
  - _instantiation_control_projection:
      - got rid of try and except double-call to controller._instantiate_control_signals
      -  outdented call to self.controller._activate_projections_for_composition at end

- controlmechanism.py:
    - _check_for_duplicates:  add warning and return duplicates

- optimizationcontrolmechanism._instantiate_control_signals:
    - add call to self.agent_rep._get_control_signals_for_composition() to get local control specs (on mechs in comp)
    - eliminate duplicates with control_signal specs on OCM
    - instantiate local + ocm control_signals

- parameterestimationcomposition.py
  - added context to various calls

* see later commit

* see later commit

* see later commit

* see later commit

* - This branch passes all tests except:
   - test_parameterestimationcomposition
   - test_composition/test_partially_overlapping_control_specs (ADDED IN THIS COMMINT)

- All relevant changes to this branch are marked as "11/21/21."
  However, most are commented out as they break other things.

- The tests above both involve local control specifications (on mechanism within a nested comp)
  and on the OCM for the outer composition, some of which are for the same nested mechs

- Both tests fail with:
   "AttributeError: 'NoneType' object has no attribute '_get_by_time_scale'" (in component.py LINE 3276)
   This may be due to a problem with context setting, since the error is because the modulation Parameter
   of the ControlProjection is returning "None" rather than "multiplicative_param" (when called with get(context)),
   whereas "multiplicative_param" is returned with a call to get() (i.e., with no context specified)

- Most of test_partially_overlapping_control_specs is passed if
   changes marked "11/21/21 NEW" in optimizationcontrolmechanism.py (LINE 1390) are implemented,
   but it does not properly route ControlProjections through parameter_CIMS (see last assert in test).
   Furthermore, test_parameterestimationcompsition fails with the mod param error, even though the
   model has similar structure (i.e., outer composition -- in this case a ParameterEstimationComposition)
   with an OCM that is given control specs that overlap with ones in a nested composition.

- There are also several other things in composition I found puzzling and tried modifying, but that cuased failures:
  - _get_control_signals_for_composition():
      - seems "if node.controller" should be "if **not** node.controller" (emphasis added just for comment)
      - "append" should be "extend"
  - _instantiate_control_projection():
      -  call to self.controller._activate_projections_for_composition (at end of method) should not be indented

* - small mods; don't impact anything relevant to prior commit message

* - small mods; don't impact anything relevant to prior commit message

* - small mods; don't impact anything relevant to prior commit message

* - finished adding formatting regions to composition.py

* -

* • composition.py:
  - rename _check_projection_initialization_status -> _check_controller_initialization_status
  - add _check_nodes_initialization_status(context=context)
    (and calls it with _check_controller_initialization_status)

* • show_graph.py:  addressed bug associated with ocm.allow_direct_probe

* • show_graph.py:  addressed bug associated with ocm.allow_direct_probe

* -

* Composition: add_controller: set METHOD as context source early

* -

* • composition.py
  retore append of control_signals in _instantiate_control_projections()

* • composition.py
  restore append of control_signals in _instantiate_control_projections()

• test_composition.py:
  add test_partially_overlapping_local_and_control_mech_control_specs_in_unnested_and_nested_comp

* • test_partially_overlapping_local_and_control_mech_control_specs_in_unnested_and_nested_comp():
  - added clear_registry() to allow names to be reused in both runs of test

* • composition.py
  docstring:  added projections entry to list of attributes
  - add_controller:  added call to _add_node_aux_components() for controller

* • composition.py
  _add_node_aux_components(): added deletion of item from aux_components if instantiated

* • composition.py
  - comment out _add_node_aux_components() (causing new failures)
  - move _instantiate_control_projections to be with _instantiate_control_projections,
       after self.add_node(self.controller.objective_mechanism (to be more orderly)

* -

* - confirm that it passes all tests exception test_composition/test_partially_overlapping...
  (with addition of _add_aux_components in add_controller commented out)

* • composition.py:  some more fixed to add_controller that now fail only one test:
    - test_agent_rep_assignement_as_controller_and_replacement

* • Passes *all* current tests

* • composition.py:
  - add_controller:  few more minor mods;
  still passes all tests

* -

* -

* -

* • controlmechanism.py:
  - __init__: resrict specification to only one of control, modulatory_signals, or control_signals (synonyms)

* -

* • composition.py:  in progress fix of bug in instantiating shadow projections for ocm.state_input_ports

* • composition.py:
  - _get_original_senders():  added support for nested composition
    needs to be checked for more than one level
    needs to be refactored to be recursive

* • optimizationcontrolmechanism.py
  - _update_state_input_ports_for_controller:  fix invalid_state_features to allow input_CIM of nested comp in agent_rep

* -

* • composition.py
 - _get_original_senders: made recursive

* • test_show_graph.py: update for fixes

* -

* • tests:  passes all in test_show_graph.py and test_report.py

* Passes all tests

* - comment clean-up

* • composition.py
 - add_controller and _get_nested_node_CIM_port:
   added support for forced assignment of NodeRole.OUTPUT for nodes specified in OCM.monitor_for_control,
   but referenced 'allow_probes' attribute still needs to be implemented

* • composition.py, optimizationcontrolmechanism.py:
  allow_probes fully implemented

* • show_graph.py:  fixed bug causing extra projections to OCM

* • composition.py:
  - _update_shadow_projections(): fix handling of deep nesting

* • optimizationcontrolmechanism.py: add agent_rep_type property

* • optimizationcontrolmechanism.py:
  - state_feature_function -> state_feature_functions

* • optimizationcontrolmechanism.py:
  - _validate_params:  validate state_feature_functions
  - _update_state_input_ports_for_controller: implement assignment of state_feature_functions

* -

* -

* • Passes all tests except test_json with 'model_with_control'

* -

* • composition.py
  - add_projection:  delete instantiation of shadow projections (handled by _update_shadow_projections)

* • composition.py
  - add_projection:  delete instantiation of shadow projections (handled by _update_shadow_projections)
  - remove calls to _update_shadows_dict

* • composition.py
  - add_projection:  delete instantiation of shadow projections (handled by _update_shadow_projections)
  - remove calls to _update_shadows_dict

* -

* • test_two_origins_two_input_ports:  crashes on failure of C->B to update

* -

* • composition.py
  - added property shadowing_dict that has shadowing ports as keys and the ports they shadow as values
  - refactored _update_shadowing_projections to use shadowing_dict

* • optimizationcontrolmechanism.py
  - _update_state_input_ports:  modified validations for nested nodes;  still failing some tests

* • optimizationcontrolmechanism.py
  - _update_state_input_ports:
     more careful and informative validation that state_input_ports are in comp or nested comp and are INPUT nodes thereof;
     passes all tests except test_two_origins_two_input_ports as before

* • composition.py
  _get_invalid_aux_components():  defer all shadow projections until _update_shadow_projections

* • composition.py
  _get_invalid_aux_components():  bug fix in test for shadow projections

* Port: _remove_projection_to_port: don't reduce variable below length 1

even ports with no incoming projections have variable at least length 1

* • composition.py
  add_node(): marked (but haven't removed) code block instantiating shadow_projections
   that seems now to be redundant with _update_shadow_projection

* • show_graph.py
  - _assign_cim_components: supress showing projections not in composition

* • composition.py:
  _analyze_graph():  add extra call to _determine_node_roles after _update_shadow_projections
  _run():  moved block of code at beginning initializing scheduler to after
           _complete_init_of_partially_initialized_nodes and _analyze_graph()

• show_graph.py
  - add test to all loops on projections:  "if proj in composition.projection"

* • show_graph.py
  - add show_projections_not_in_composition option for debugging

* • composition.py
  _update_shadow_projections(): delete unused shadow projections and corresponding ports

* • composition.py
  _update_shadow_projections(): fix bug in deletion of unused shadow projections and ports

• test_show_graph:  tests failing, need mods to accomodate changes

* • composition.py:
  _analyze_graph():  add extra call to _determine_node_roles after _update_shadow_projections
  _run():  moved block of code at beginning initializing scheduler to after
           _complete_init_of_partially_initialized_nodes and _analyze_graph()

• show_graph.py
  - add test to all loops on projections:  "if proj in composition.projection"

* • show_graph.py
  fixes; now passes all show_graph tests

* -

* • composition.py
  _update_shadow_projections:  raise error for attempt to shadow INTERNAL Node of nested comp

* -

* -

* • test_composition.py
  implemented test_shadow_nested_nodes that tests shadowing of nested nodes

* -

* -

* -

* -

* • optimizationcontrolmechanism.py: docstring mods

* • composition.py:
  - add allow_probes and exclude_probes_from_output

* • composition.py:
  - docstring mods re: allow_probes

• optimizationcontrolmechanism.py:
  - allow_probes:  eliminate DIRECT setting
  - remove _parse_monitor_for_control_input_ports (no longer needed without allow_probes=DIRECT)

* • composition.py:
  - change "exclude_probes_from_output" -> "include_probes_in_output"

* • composition.py:
  - docstring mods re: allow_probes and include_probes_in_output

* • composition.py:
  - docstring mods re: allow_probes and include_probes_in_output

* • controlmechanism.py:
  - add allow_probes handling (moved from OCM)

• optimizationcontrolmechanism.py:
  - move allow_probes to controlmechanism.py

• composition.py:
  - refactor handling of allow_probes to permit for any ControlMechanism

• objectivemechanism.py:
  - add modulatory_mechanism attribute

* • controlmechanism.py:
  - add allow_probes handling (moved from OCM)

• optimizationcontrolmechanism.py:
  - move allow_probes to controlmechanism.py

• composition.py:
  - refactor handling of allow_probes to permit for any ControlMechanism
  - add _handle_allow_probes_for_control() to reconcile setting on Composition and ControlMechanism

• objectivemechanism.py:
  - add modulatory_mechanism attribute

* • composition.py
  add assignment of learning_mechanism to objective_mechanism.modulatory_mechanism for add_learning methods

* • docstring mods

* -

* -

* • optimizationcontrolmechanism.py: docstring revs

* -

* -

* • test_composition.py:
  - add test_unnested_PROBE
  - add test_nested_PROBES
    TBD: test include_probes_in_output

* -

* • composition.py
  - add_node():  support tuple with required_role

* -

* • composition.py:
  - _determine_node_roles:
     fix bug in which nested comp was prevented from being an OUTPUT Node if,
     in addition to Nodes that qualifed as OUTPUT, it also had nodes that projected
     to Nodes in an outer comp (making it look like it was INTERNAL)

* -

* • composition.py:
  - add_node(): enforce include_probes_in_output = True for nested Compositions
  - execute():
    - replace return of output_value with get_output_value()

* -

* • CompositionInterfaceMechanism.rst:
  - correct path ref

• compositioninterfacemechanism.py:
  - docstring fixes

* -

* -

* • port.py:
  - refactor to eliminate:
    - efferents attribute from InputPorts and Parameters
    - path_afferents attribute from OutputPports
  - add remove_projections()
  - add mod_afferents property
  - _get_input_struct_type(): add try and accept for path_afferents
• inputport.py:
  - add path_afferents override
• parameterport.py:
  - add path_afferents override
• outputport.py:
  - add efferents override
• composition.py:
  - add_projection(): call port.remove_projection
• keywords.py:
  add PATH_AFFERENTS, MOD_AFFERENTS, EFFERENTS

* -

* • Passes all tests

* -

* • test_input_ports.py:
  - add test_no_efferents()

* • test_output_ports.py:
  - add test_no_path_afferents()

* • test_parameter_ports.py:
  - add test_no_path_afferents()
  - add test_no_efferents()

* -

* -

* -

* • composition.py:
  - add_pathways():
    add set notation: creates a Pathway for each node in set

* -

* • test_composition.py:
  - add test_composition_pathways_arg_set()

* • composition.py:
  - add_linear_processing_pathway(): allow sets in pathway specification

* -

* -

* • composition.py:
  - add_linear_processing_pathway(): refactor instantiation of projection for efficiency and to support sets

* • composition.py:
  - add_linear_processing_pathway(): refactor instantiation of Projections between entries

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* • test_composition.py:
  - test_composition_pathways_arg_with_various_set_or_list_configurations() -- all pass

* -

Co-authored-by: jdcpni <pniintel55>
Co-authored-by: Katherine Mantel <[email protected]>
if a TERMINAL node in a Composition that was not in the final
consideration set had an inactive projection to another node, the
TERMINAL role was not assigned because the active/inactive status was
not considered
* • composition.py: reorganize with #region and #enregions

* • composition.py: reorganize with #region and #enregions

* • controlmechanism.py, optimizationcontrolmechanism.py:
  - _instantiate_monitor_for_control_input_ports -> _parse_monitor_control_input_ports
  - refactored to support allow_probes option on ocm

* -

* -

* -

* • controlmechanism.py, optimizationcontrolmechanism.py:
  - _instantiate_monitor_for_control_input_ports -> _parse_monitor_control_input_ports
  - refactored to support allow_probes option on ocm

* • controlmechanism.py, optimizationcontrolmechanism.py:
  - _instantiate_monitor_for_control_input_ports -> _parse_monitor_control_input_ports
  - refactored to support allow_probes option on ocm

* -

* • composition.py:
  __init__: move controller to after add_nodes and add_linear_pathway

* -

* - test_control: only test_hanging_control_spec_outer_controller not passing

* -

* -

* -

* -

* -

* -

* • composition.py:
  _instantiate_control_projections:
     weird requirement for double-call to controller._instantiate_control_signal

* • test_paremtercomposition.py:
  restored parameter spec that causes crash ('threshold',Decision2)

* ª Attempt to fix problem with partially overlapping local and ocm control specs

- composition.py
  - _get_control_signals_for_composition:  (see 11/20/21)
      - added (but commented out change) to "if node.controller" to "if not node.controller"
      - changed append to extend
  - _instantiation_control_projection:
      - got rid of try and except double-call to controller._instantiate_control_signals
      -  outdented call to self.controller._activate_projections_for_composition at end

- controlmechanism.py:
    - _check_for_duplicates:  add warning and return duplicates

- optimizationcontrolmechanism._instantiate_control_signals:
    - add call to self.agent_rep._get_control_signals_for_composition() to get local control specs (on mechs in comp)
    - eliminate duplicates with control_signal specs on OCM
    - instantiate local + ocm control_signals

- parameterestimationcomposition.py
  - added context to various calls

* see later commit

* see later commit

* see later commit

* see later commit

* - This branch passes all tests except:
   - test_parameterestimationcomposition
   - test_composition/test_partially_overlapping_control_specs (ADDED IN THIS COMMINT)

- All relevant changes to this branch are marked as "11/21/21."
  However, most are commented out as they break other things.

- The tests above both involve local control specifications (on mechanism within a nested comp)
  and on the OCM for the outer composition, some of which are for the same nested mechs

- Both tests fail with:
   "AttributeError: 'NoneType' object has no attribute '_get_by_time_scale'" (in component.py LINE 3276)
   This may be due to a problem with context setting, since the error is because the modulation Parameter
   of the ControlProjection is returning "None" rather than "multiplicative_param" (when called with get(context)),
   whereas "multiplicative_param" is returned with a call to get() (i.e., with no context specified)

- Most of test_partially_overlapping_control_specs is passed if
   changes marked "11/21/21 NEW" in optimizationcontrolmechanism.py (LINE 1390) are implemented,
   but it does not properly route ControlProjections through parameter_CIMS (see last assert in test).
   Furthermore, test_parameterestimationcompsition fails with the mod param error, even though the
   model has similar structure (i.e., outer composition -- in this case a ParameterEstimationComposition)
   with an OCM that is given control specs that overlap with ones in a nested composition.

- There are also several other things in composition I found puzzling and tried modifying, but that cuased failures:
  - _get_control_signals_for_composition():
      - seems "if node.controller" should be "if **not** node.controller" (emphasis added just for comment)
      - "append" should be "extend"
  - _instantiate_control_projection():
      -  call to self.controller._activate_projections_for_composition (at end of method) should not be indented

* - small mods; don't impact anything relevant to prior commit message

* - small mods; don't impact anything relevant to prior commit message

* - small mods; don't impact anything relevant to prior commit message

* - finished adding formatting regions to composition.py

* -

* • composition.py:
  - rename _check_projection_initialization_status -> _check_controller_initialization_status
  - add _check_nodes_initialization_status(context=context)
    (and calls it with _check_controller_initialization_status)

* • show_graph.py:  addressed bug associated with ocm.allow_direct_probe

* • show_graph.py:  addressed bug associated with ocm.allow_direct_probe

* -

* Composition: add_controller: set METHOD as context source early

* -

* • composition.py
  retore append of control_signals in _instantiate_control_projections()

* • composition.py
  restore append of control_signals in _instantiate_control_projections()

• test_composition.py:
  add test_partially_overlapping_local_and_control_mech_control_specs_in_unnested_and_nested_comp

* • test_partially_overlapping_local_and_control_mech_control_specs_in_unnested_and_nested_comp():
  - added clear_registry() to allow names to be reused in both runs of test

* • composition.py
  docstring:  added projections entry to list of attributes
  - add_controller:  added call to _add_node_aux_components() for controller

* • composition.py
  _add_node_aux_components(): added deletion of item from aux_components if instantiated

* • composition.py
  - comment out _add_node_aux_components() (causing new failures)
  - move _instantiate_control_projections to be with _instantiate_control_projections,
       after self.add_node(self.controller.objective_mechanism (to be more orderly)

* -

* - confirm that it passes all tests exception test_composition/test_partially_overlapping...
  (with addition of _add_aux_components in add_controller commented out)

* • composition.py:  some more fixed to add_controller that now fail only one test:
    - test_agent_rep_assignement_as_controller_and_replacement

* • Passes *all* current tests

* • composition.py:
  - add_controller:  few more minor mods;
  still passes all tests

* -

* -

* -

* • controlmechanism.py:
  - __init__: resrict specification to only one of control, modulatory_signals, or control_signals (synonyms)

* -

* • composition.py:  in progress fix of bug in instantiating shadow projections for ocm.state_input_ports

* • composition.py:
  - _get_original_senders():  added support for nested composition
    needs to be checked for more than one level
    needs to be refactored to be recursive

* • optimizationcontrolmechanism.py
  - _update_state_input_ports_for_controller:  fix invalid_state_features to allow input_CIM of nested comp in agent_rep

* -

* • composition.py
 - _get_original_senders: made recursive

* • test_show_graph.py: update for fixes

* -

* • tests:  passes all in test_show_graph.py and test_report.py

* Passes all tests

* - comment clean-up

* • composition.py
 - add_controller and _get_nested_node_CIM_port:
   added support for forced assignment of NodeRole.OUTPUT for nodes specified in OCM.monitor_for_control,
   but referenced 'allow_probes' attribute still needs to be implemented

* • composition.py, optimizationcontrolmechanism.py:
  allow_probes fully implemented

* • show_graph.py:  fixed bug causing extra projections to OCM

* • composition.py:
  - _update_shadow_projections(): fix handling of deep nesting

* • optimizationcontrolmechanism.py: add agent_rep_type property

* • optimizationcontrolmechanism.py:
  - state_feature_function -> state_feature_functions

* • optimizationcontrolmechanism.py:
  - _validate_params:  validate state_feature_functions
  - _update_state_input_ports_for_controller: implement assignment of state_feature_functions

* -

* -

* • Passes all tests except test_json with 'model_with_control'

* -

* • composition.py
  - add_projection:  delete instantiation of shadow projections (handled by _update_shadow_projections)

* • composition.py
  - add_projection:  delete instantiation of shadow projections (handled by _update_shadow_projections)
  - remove calls to _update_shadows_dict

* • composition.py
  - add_projection:  delete instantiation of shadow projections (handled by _update_shadow_projections)
  - remove calls to _update_shadows_dict

* -

* • test_two_origins_two_input_ports:  crashes on failure of C->B to update

* -

* • composition.py
  - added property shadowing_dict that has shadowing ports as keys and the ports they shadow as values
  - refactored _update_shadowing_projections to use shadowing_dict

* • optimizationcontrolmechanism.py
  - _update_state_input_ports:  modified validations for nested nodes;  still failing some tests

* • optimizationcontrolmechanism.py
  - _update_state_input_ports:
     more careful and informative validation that state_input_ports are in comp or nested comp and are INPUT nodes thereof;
     passes all tests except test_two_origins_two_input_ports as before

* • composition.py
  _get_invalid_aux_components():  defer all shadow projections until _update_shadow_projections

* • composition.py
  _get_invalid_aux_components():  bug fix in test for shadow projections

* Port: _remove_projection_to_port: don't reduce variable below length 1

even ports with no incoming projections have variable at least length 1

* • composition.py
  add_node(): marked (but haven't removed) code block instantiating shadow_projections
   that seems now to be redundant with _update_shadow_projection

* • show_graph.py
  - _assign_cim_components: supress showing projections not in composition

* • composition.py:
  _analyze_graph():  add extra call to _determine_node_roles after _update_shadow_projections
  _run():  moved block of code at beginning initializing scheduler to after
           _complete_init_of_partially_initialized_nodes and _analyze_graph()

• show_graph.py
  - add test to all loops on projections:  "if proj in composition.projection"

* • show_graph.py
  - add show_projections_not_in_composition option for debugging

* • composition.py
  _update_shadow_projections(): delete unused shadow projections and corresponding ports

* • composition.py
  _update_shadow_projections(): fix bug in deletion of unused shadow projections and ports

• test_show_graph:  tests failing, need mods to accomodate changes

* • composition.py:
  _analyze_graph():  add extra call to _determine_node_roles after _update_shadow_projections
  _run():  moved block of code at beginning initializing scheduler to after
           _complete_init_of_partially_initialized_nodes and _analyze_graph()

• show_graph.py
  - add test to all loops on projections:  "if proj in composition.projection"

* • show_graph.py
  fixes; now passes all show_graph tests

* -

* • composition.py
  _update_shadow_projections:  raise error for attempt to shadow INTERNAL Node of nested comp

* -

* -

* • test_composition.py
  implemented test_shadow_nested_nodes that tests shadowing of nested nodes

* -

* -

* -

* -

* • optimizationcontrolmechanism.py: docstring mods

* • composition.py:
  - add allow_probes and exclude_probes_from_output

* • composition.py:
  - docstring mods re: allow_probes

• optimizationcontrolmechanism.py:
  - allow_probes:  eliminate DIRECT setting
  - remove _parse_monitor_for_control_input_ports (no longer needed without allow_probes=DIRECT)

* • composition.py:
  - change "exclude_probes_from_output" -> "include_probes_in_output"

* • composition.py:
  - docstring mods re: allow_probes and include_probes_in_output

* • composition.py:
  - docstring mods re: allow_probes and include_probes_in_output

* • controlmechanism.py:
  - add allow_probes handling (moved from OCM)

• optimizationcontrolmechanism.py:
  - move allow_probes to controlmechanism.py

• composition.py:
  - refactor handling of allow_probes to permit for any ControlMechanism

• objectivemechanism.py:
  - add modulatory_mechanism attribute

* • controlmechanism.py:
  - add allow_probes handling (moved from OCM)

• optimizationcontrolmechanism.py:
  - move allow_probes to controlmechanism.py

• composition.py:
  - refactor handling of allow_probes to permit for any ControlMechanism
  - add _handle_allow_probes_for_control() to reconcile setting on Composition and ControlMechanism

• objectivemechanism.py:
  - add modulatory_mechanism attribute

* • composition.py
  add assignment of learning_mechanism to objective_mechanism.modulatory_mechanism for add_learning methods

* • docstring mods

* -

* -

* • optimizationcontrolmechanism.py: docstring revs

* -

* -

* • test_composition.py:
  - add test_unnested_PROBE
  - add test_nested_PROBES
    TBD: test include_probes_in_output

* -

* • composition.py
  - add_node():  support tuple with required_role

* -

* • composition.py:
  - _determine_node_roles:
     fix bug in which nested comp was prevented from being an OUTPUT Node if,
     in addition to Nodes that qualifed as OUTPUT, it also had nodes that projected
     to Nodes in an outer comp (making it look like it was INTERNAL)

* -

* • composition.py:
  - add_node(): enforce include_probes_in_output = True for nested Compositions
  - execute():
    - replace return of output_value with get_output_value()

* -

* • CompositionInterfaceMechanism.rst:
  - correct path ref

• compositioninterfacemechanism.py:
  - docstring fixes

* -

* -

* • port.py:
  - refactor to eliminate:
    - efferents attribute from InputPorts and Parameters
    - path_afferents attribute from OutputPports
  - add remove_projections()
  - add mod_afferents property
  - _get_input_struct_type(): add try and accept for path_afferents
• inputport.py:
  - add path_afferents override
• parameterport.py:
  - add path_afferents override
• outputport.py:
  - add efferents override
• composition.py:
  - add_projection(): call port.remove_projection
• keywords.py:
  add PATH_AFFERENTS, MOD_AFFERENTS, EFFERENTS

* -

* • Passes all tests

* -

* • test_input_ports.py:
  - add test_no_efferents()

* • test_output_ports.py:
  - add test_no_path_afferents()

* • test_parameter_ports.py:
  - add test_no_path_afferents()
  - add test_no_efferents()

* -

* -

* -

* • composition.py:
  - add_pathways():
    add set notation: creates a Pathway for each node in set

* -

* • test_composition.py:
  - add test_composition_pathways_arg_set()

* • composition.py:
  - add_linear_processing_pathway(): allow sets in pathway specification

* -

* -

* • composition.py:
  - add_linear_processing_pathway(): refactor instantiation of projection for efficiency and to support sets

* • composition.py:
  - add_linear_processing_pathway(): refactor instantiation of Projections between entries

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* -

* • test_composition.py:
  - test_composition_pathways_arg_with_various_set_or_list_configurations() -- all pass

* -

* • composition.py:
  - add_pathways() and add_linear_processing_pathway():
    - manage embedded lists more consistently
    - revise error messages accordingly

* -

* -

* • test_composition.py:
  - add test_various_pathway_configurations_in_constructor()

* • test_composition.py:
  - add test_various_pathway_configurations_in_constructor()

* -

* -

* -

* -

* • composition.py, pathway.py:
  - move documentation of Pathway specification from _add_linear_processing_pathway() to Pathway()

* -

* -

* -

* • test_composition_pathways_arg_with_various_set_or_list_configurations()
  - restore SINGLETON assertions after TERMINAL bug fix

* -

* • pathway.py:
  Pathway(): figure with examples of specifications added to docstring

* -

* -

* -

Co-authored-by: jdcpni <pniintel55>
Co-authored-by: Katherine Mantel <[email protected]>
@github-actions
Copy link

This PR causes the following changes to the html docs (ubuntu-latest-3.7-x64):

diff -r docs-base/BasicsAndPrimer.html docs-head/BasicsAndPrimer.html
308c308
< of computational models in neuroscience and psychology (see <a class="reference internal" href="mdf.html#module-psyneulink.core.globals.json" title="psyneulink.core.globals.json"><code class="xref any py py-mod docutils literal notranslate"><span class="pre">json</span></code></a>)</p>
---
> of computational models in neuroscience and psychology (see <code class="xref any docutils literal notranslate"><span class="pre">json</span></code>)</p>
diff -r docs-base/Composition.html docs-head/Composition.html
400a401
> <div><blockquote id="composition-pathways-arg">
403,405c404,410
< <dt><strong>nodes</strong></dt><dd><p>adds the specified <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> to the Composition;  this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_nodes" title="psyneulink.core.compositions.composition.Composition.add_nodes"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_nodes</span></code></a> method, and takes the same values as the
< <strong>nodes</strong> argument of that method.</p>
---
> <dt><strong>pathways</strong></dt><dd><p>adds one or more <a class="reference internal" href="#composition-pathways"><span class="std std-ref">Pathways</span></a> to the Composition; this is equivalent to constructing
> the Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method, and can use the
> same forms of specification as the <strong>pathways</strong> argument of that method (see <a class="reference internal" href="Pathway.html#pathway-specification"><span class="std std-ref">Pathway Specification</span></a> for
> additonal details). If any <a class="reference internal" href="#composition-learning-pathway"><span class="std std-ref">learning Pathways</span></a> are included, then the
> constructor’s <strong>disable_learning</strong> argument can be used to disable learning on those by default (though it
> will still allow learning to occur on any other Compositions, either nested within the current one,
> or within which the current one is nested (see <a class="reference internal" href="#composition-learning"><span class="std std-ref">Learning in a Composition</span></a> for a full description).</p>
408a414,417
> </ul>
> </div></blockquote>
> <blockquote id="composition-nodes-arg">
> <div><ul class="simple">
410,412c419,422
< <dt><strong>projections</strong></dt><dd><p>adds the specified <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition;  this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_projections" title="psyneulink.core.compositions.composition.Composition.add_projections"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_projections</span></code></a> method, and takes the same
< values as the <strong>projections</strong> argument of that method.</p>
---
> <dt><strong>nodes</strong></dt><dd><p>adds the specified <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> to the Composition;  this is equivalent to constructing the
> Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_nodes" title="psyneulink.core.compositions.composition.Composition.add_nodes"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_nodes</span></code></a> method, and takes the same values as the
> <strong>nodes</strong> argument of that method (note that this does <em>not</em> construct <a class="reference internal" href="Pathway.html"><span class="doc">Pathways</span></a> for the specified
> nodes; the <strong>pathways</strong> arg or  <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method must be used to do so).</p>
416,422c426,438
< <li><dl class="simple">
< <dt><strong>pathways</strong></dt><dd><p>adds one or more <a class="reference internal" href="#composition-pathways"><span class="std std-ref">Pathways</span></a> to the Composition; this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method, and can use the same forms
< of specification as the <strong>pathways</strong> argument of that method.  If any <a class="reference internal" href="#composition-learning-pathway"><span class="std std-ref">learning Pathways</span></a> are included, then the constructor’s <strong>disable_learning</strong> argument can be
< used to disable learning on those by default (though it will still allow learning to occur on any other
< Compositions, either nested within the current one, or within which the current one is nested (see
< <a class="reference internal" href="#composition-learning"><span class="std std-ref">Learning in a Composition</span></a> for a full description).</p>
---
> </ul>
> </div></blockquote>
> <blockquote id="composition-projections-arg">
> <div><ul>
> <li><dl>
> <dt><strong>projections</strong></dt><dd><p>adds the specified <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition;  this is equivalent to constructing the
> Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_projections" title="psyneulink.core.compositions.composition.Composition.add_projections"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_projections</span></code></a> method, and takes the same
> values as the <strong>projections</strong> argument of that method.  In general, this is not neded – default Projections
> are created for Pathways and/or Nodes added to the Composition using the methods described above; however
> it can be useful for custom configurations, including the implementation of specific Projection <a href="#id1"><span class="problematic" id="id2">`</span></a>matrices</p>
> <blockquote>
> <div><p>&lt;MappingProjection.matrix&gt;`.</p>
> </div></blockquote>
425a442,445
> </ul>
> </div></blockquote>
> <blockquote id="composition-controller-arg">
> <div><ul class="simple">
435a456
> </div></blockquote>
483,486c504,507
< <div><p>adds and a list of <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> and <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition,
< inserting a default Projection between any adjacent pair of Nodes for which one is not otherwise specified
< (or possibly a set of Projections if either Node is a Composition – see method documentation for details);
< returns the <a class="reference internal" href="Pathway.html"><span class="doc">Pathway</span></a> added to the Composition.</p>
---
> <div><p>adds and a list of <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> and <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition, inserting
> a default Projection between any adjacent set(s) of Nodes for which a Projection is not otherwise specified
> (see method documentation and <a class="reference internal" href="Pathway.html#pathway-specification"><span class="std std-ref">Pathway Specification</span></a> for additonal details); returns the <a class="reference internal" href="Pathway.html"><span class="doc">Pathway</span></a> added to
> the Composition.</p>
533c554
< <span id="id1"></span><h2>Composition Structure<a class="headerlink" href="#composition-structure" title="Permalink to this headline">¶</a></h2>
---
> <span id="id3"></span><h2>Composition Structure<a class="headerlink" href="#composition-structure" title="Permalink to this headline">¶</a></h2>
607,609c628,630
< outer Composition, are assigned <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> in addition to their other <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole" title="psyneulink.core.compositions.composition.NodeRole"><code class="xref any py py-class docutils literal notranslate"><span class="pre">roles</span></code></a> in the
< nested Composition.  The only difference between <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole.OUTPUT" title="psyneulink.core.compositions.composition.NodeRole.OUTPUT"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">OUTPUT</span></code></a> Nodes
< is whether their output is included in the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> attributes of the <em>outermost</em> Composition to which they project; this is determined by the
---
> outer Composition, are assigned <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> in addition to their other <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole" title="psyneulink.core.compositions.composition.NodeRole"><code class="xref any py py-class docutils literal notranslate"><span class="pre">roles</span></code></a> in the
> nested Composition.  The only difference between <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole.OUTPUT" title="psyneulink.core.compositions.composition.NodeRole.OUTPUT"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">OUTPUT</span></code></a> Nodes
> is whether their output is included in the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> attributes of the <em>outermost</em> Composition to which they project; this is determined by the
612c633
< <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes are <em>not</em> included in the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> or <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> for the outermost Composition to which they project (although they <em>are</em> still included
---
> <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes are <em>not</em> included in the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> or <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> for the outermost Composition to which they project (although they <em>are</em> still included
616c637
< <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.include_probes_in_output" title="psyneulink.core.compositions.composition.Composition.include_probes_in_output"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">include_probes_in_output</span></code></a> is True, then any <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes
---
> <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.include_probes_in_output" title="psyneulink.core.compositions.composition.Composition.include_probes_in_output"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">include_probes_in_output</span></code></a> is True, then any <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes
618,619c639,640
< the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> of the outermost Composition.
< <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes can be visualized, along with any Projections treated differently from those of
---
> the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" tit
...

See CI logs for the full diff.

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Jul 25, 2022

This pull request introduces 2 alerts and fixes 17 when merging 508935c into 7072684 - view on LGTM.com

new alerts:

  • 2 for Unused import

fixed alerts:

  • 12 for `__init__` method calls overridden method
  • 2 for Unused argument in a formatting call
  • 1 for Formatting string mixes implicitly and explicitly numbered fields
  • 1 for Missing call to `__init__` during object initialization
  • 1 for Wrong name for an argument in a class instantiation

@coveralls
Copy link

coveralls commented Jul 26, 2022

Coverage Status

Coverage increased (+0.2%) to 84.451% when pulling 0be359f on devel into 7072684 on master.

@kmantel kmantel requested a review from jdcpni July 26, 2022 18:45
@dependabot dependabot bot temporarily deployed to github-pages July 27, 2022 03:03 Inactive
@github-actions
Copy link

This PR causes the following changes to the html docs (ubuntu-latest-3.7-x64):

diff -r docs-base/BasicsAndPrimer.html docs-head/BasicsAndPrimer.html
308c308
< of computational models in neuroscience and psychology (see <a class="reference internal" href="mdf.html#module-psyneulink.core.globals.json" title="psyneulink.core.globals.json"><code class="xref any py py-mod docutils literal notranslate"><span class="pre">json</span></code></a>)</p>
---
> of computational models in neuroscience and psychology (see <code class="xref any docutils literal notranslate"><span class="pre">json</span></code>)</p>
diff -r docs-base/Composition.html docs-head/Composition.html
400a401
> <div><blockquote id="composition-pathways-arg">
403,405c404,410
< <dt><strong>nodes</strong></dt><dd><p>adds the specified <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> to the Composition;  this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_nodes" title="psyneulink.core.compositions.composition.Composition.add_nodes"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_nodes</span></code></a> method, and takes the same values as the
< <strong>nodes</strong> argument of that method.</p>
---
> <dt><strong>pathways</strong></dt><dd><p>adds one or more <a class="reference internal" href="#composition-pathways"><span class="std std-ref">Pathways</span></a> to the Composition; this is equivalent to constructing
> the Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method, and can use the
> same forms of specification as the <strong>pathways</strong> argument of that method (see <a class="reference internal" href="Pathway.html#pathway-specification"><span class="std std-ref">Pathway Specification</span></a> for
> additonal details). If any <a class="reference internal" href="#composition-learning-pathway"><span class="std std-ref">learning Pathways</span></a> are included, then the
> constructor’s <strong>disable_learning</strong> argument can be used to disable learning on those by default (though it
> will still allow learning to occur on any other Compositions, either nested within the current one,
> or within which the current one is nested (see <a class="reference internal" href="#composition-learning"><span class="std std-ref">Learning in a Composition</span></a> for a full description).</p>
408a414,417
> </ul>
> </div></blockquote>
> <blockquote id="composition-nodes-arg">
> <div><ul class="simple">
410,412c419,422
< <dt><strong>projections</strong></dt><dd><p>adds the specified <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition;  this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_projections" title="psyneulink.core.compositions.composition.Composition.add_projections"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_projections</span></code></a> method, and takes the same
< values as the <strong>projections</strong> argument of that method.</p>
---
> <dt><strong>nodes</strong></dt><dd><p>adds the specified <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> to the Composition;  this is equivalent to constructing the
> Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_nodes" title="psyneulink.core.compositions.composition.Composition.add_nodes"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_nodes</span></code></a> method, and takes the same values as the
> <strong>nodes</strong> argument of that method (note that this does <em>not</em> construct <a class="reference internal" href="Pathway.html"><span class="doc">Pathways</span></a> for the specified
> nodes; the <strong>pathways</strong> arg or  <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method must be used to do so).</p>
416,422c426,438
< <li><dl class="simple">
< <dt><strong>pathways</strong></dt><dd><p>adds one or more <a class="reference internal" href="#composition-pathways"><span class="std std-ref">Pathways</span></a> to the Composition; this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method, and can use the same forms
< of specification as the <strong>pathways</strong> argument of that method.  If any <a class="reference internal" href="#composition-learning-pathway"><span class="std std-ref">learning Pathways</span></a> are included, then the constructor’s <strong>disable_learning</strong> argument can be
< used to disable learning on those by default (though it will still allow learning to occur on any other
< Compositions, either nested within the current one, or within which the current one is nested (see
< <a class="reference internal" href="#composition-learning"><span class="std std-ref">Learning in a Composition</span></a> for a full description).</p>
---
> </ul>
> </div></blockquote>
> <blockquote id="composition-projections-arg">
> <div><ul>
> <li><dl>
> <dt><strong>projections</strong></dt><dd><p>adds the specified <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition;  this is equivalent to constructing the
> Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_projections" title="psyneulink.core.compositions.composition.Composition.add_projections"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_projections</span></code></a> method, and takes the same
> values as the <strong>projections</strong> argument of that method.  In general, this is not neded – default Projections
> are created for Pathways and/or Nodes added to the Composition using the methods described above; however
> it can be useful for custom configurations, including the implementation of specific Projection <a href="#id1"><span class="problematic" id="id2">`</span></a>matrices</p>
> <blockquote>
> <div><p>&lt;MappingProjection.matrix&gt;`.</p>
> </div></blockquote>
425a442,445
> </ul>
> </div></blockquote>
> <blockquote id="composition-controller-arg">
> <div><ul class="simple">
435a456
> </div></blockquote>
483,486c504,507
< <div><p>adds and a list of <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> and <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition,
< inserting a default Projection between any adjacent pair of Nodes for which one is not otherwise specified
< (or possibly a set of Projections if either Node is a Composition – see method documentation for details);
< returns the <a class="reference internal" href="Pathway.html"><span class="doc">Pathway</span></a> added to the Composition.</p>
---
> <div><p>adds and a list of <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> and <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition, inserting
> a default Projection between any adjacent set(s) of Nodes for which a Projection is not otherwise specified
> (see method documentation and <a class="reference internal" href="Pathway.html#pathway-specification"><span class="std std-ref">Pathway Specification</span></a> for additonal details); returns the <a class="reference internal" href="Pathway.html"><span class="doc">Pathway</span></a> added to
> the Composition.</p>
533c554
< <span id="id1"></span><h2>Composition Structure<a class="headerlink" href="#composition-structure" title="Permalink to this headline">¶</a></h2>
---
> <span id="id3"></span><h2>Composition Structure<a class="headerlink" href="#composition-structure" title="Permalink to this headline">¶</a></h2>
607,609c628,630
< outer Composition, are assigned <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> in addition to their other <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole" title="psyneulink.core.compositions.composition.NodeRole"><code class="xref any py py-class docutils literal notranslate"><span class="pre">roles</span></code></a> in the
< nested Composition.  The only difference between <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole.OUTPUT" title="psyneulink.core.compositions.composition.NodeRole.OUTPUT"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">OUTPUT</span></code></a> Nodes
< is whether their output is included in the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> attributes of the <em>outermost</em> Composition to which they project; this is determined by the
---
> outer Composition, are assigned <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> in addition to their other <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole" title="psyneulink.core.compositions.composition.NodeRole"><code class="xref any py py-class docutils literal notranslate"><span class="pre">roles</span></code></a> in the
> nested Composition.  The only difference between <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole.OUTPUT" title="psyneulink.core.compositions.composition.NodeRole.OUTPUT"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">OUTPUT</span></code></a> Nodes
> is whether their output is included in the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> attributes of the <em>outermost</em> Composition to which they project; this is determined by the
612c633
< <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes are <em>not</em> included in the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> or <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> for the outermost Composition to which they project (although they <em>are</em> still included
---
> <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes are <em>not</em> included in the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> or <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> for the outermost Composition to which they project (although they <em>are</em> still included
616c637
< <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.include_probes_in_output" title="psyneulink.core.compositions.composition.Composition.include_probes_in_output"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">include_probes_in_output</span></code></a> is True, then any <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes
---
> <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.include_probes_in_output" title="psyneulink.core.compositions.composition.Composition.include_probes_in_output"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">include_probes_in_output</span></code></a> is True, then any <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes
618,619c639,640
< the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> of the outermost Composition.
< <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes can be visualized, along with any Projections treated differently from those of
---
> the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" tit
...

See CI logs for the full diff.

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Jul 27, 2022

This pull request introduces 2 alerts and fixes 17 when merging dccb43c into 7072684 - view on LGTM.com

new alerts:

  • 2 for Unused import

fixed alerts:

  • 12 for `__init__` method calls overridden method
  • 2 for Unused argument in a formatting call
  • 1 for Formatting string mixes implicitly and explicitly numbered fields
  • 1 for Missing call to `__init__` during object initialization
  • 1 for Wrong name for an argument in a class instantiation

@jvesely
Copy link
Collaborator

jvesely commented Jul 27, 2022

Can this wait one more day?
github actions is deprecating macos-10.15 (#2453),
and we should be able to update to numpy 1.21.6 to avoid security warning.

EDIT: All merged now

Python 3.7 is broken on macos-11 [0],
at the same time macos-10.15 will be removed by github-actions[1].

[0] actions/runner-images#4230
[1] actions/runner-images#5583

Signed-off-by: Jan Vesely <[email protected]>
@jvesely jvesely temporarily deployed to github-pages July 27, 2022 06:54 Inactive
@github-actions
Copy link

This PR causes the following changes to the html docs (ubuntu-latest-3.7-x64):

diff -r docs-base/BasicsAndPrimer.html docs-head/BasicsAndPrimer.html
308c308
< of computational models in neuroscience and psychology (see <a class="reference internal" href="mdf.html#module-psyneulink.core.globals.json" title="psyneulink.core.globals.json"><code class="xref any py py-mod docutils literal notranslate"><span class="pre">json</span></code></a>)</p>
---
> of computational models in neuroscience and psychology (see <code class="xref any docutils literal notranslate"><span class="pre">json</span></code>)</p>
diff -r docs-base/Composition.html docs-head/Composition.html
400a401
> <div><blockquote id="composition-pathways-arg">
403,405c404,410
< <dt><strong>nodes</strong></dt><dd><p>adds the specified <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> to the Composition;  this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_nodes" title="psyneulink.core.compositions.composition.Composition.add_nodes"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_nodes</span></code></a> method, and takes the same values as the
< <strong>nodes</strong> argument of that method.</p>
---
> <dt><strong>pathways</strong></dt><dd><p>adds one or more <a class="reference internal" href="#composition-pathways"><span class="std std-ref">Pathways</span></a> to the Composition; this is equivalent to constructing
> the Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method, and can use the
> same forms of specification as the <strong>pathways</strong> argument of that method (see <a class="reference internal" href="Pathway.html#pathway-specification"><span class="std std-ref">Pathway Specification</span></a> for
> additonal details). If any <a class="reference internal" href="#composition-learning-pathway"><span class="std std-ref">learning Pathways</span></a> are included, then the
> constructor’s <strong>disable_learning</strong> argument can be used to disable learning on those by default (though it
> will still allow learning to occur on any other Compositions, either nested within the current one,
> or within which the current one is nested (see <a class="reference internal" href="#composition-learning"><span class="std std-ref">Learning in a Composition</span></a> for a full description).</p>
408a414,417
> </ul>
> </div></blockquote>
> <blockquote id="composition-nodes-arg">
> <div><ul class="simple">
410,412c419,422
< <dt><strong>projections</strong></dt><dd><p>adds the specified <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition;  this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_projections" title="psyneulink.core.compositions.composition.Composition.add_projections"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_projections</span></code></a> method, and takes the same
< values as the <strong>projections</strong> argument of that method.</p>
---
> <dt><strong>nodes</strong></dt><dd><p>adds the specified <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> to the Composition;  this is equivalent to constructing the
> Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_nodes" title="psyneulink.core.compositions.composition.Composition.add_nodes"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_nodes</span></code></a> method, and takes the same values as the
> <strong>nodes</strong> argument of that method (note that this does <em>not</em> construct <a class="reference internal" href="Pathway.html"><span class="doc">Pathways</span></a> for the specified
> nodes; the <strong>pathways</strong> arg or  <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method must be used to do so).</p>
416,422c426,438
< <li><dl class="simple">
< <dt><strong>pathways</strong></dt><dd><p>adds one or more <a class="reference internal" href="#composition-pathways"><span class="std std-ref">Pathways</span></a> to the Composition; this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method, and can use the same forms
< of specification as the <strong>pathways</strong> argument of that method.  If any <a class="reference internal" href="#composition-learning-pathway"><span class="std std-ref">learning Pathways</span></a> are included, then the constructor’s <strong>disable_learning</strong> argument can be
< used to disable learning on those by default (though it will still allow learning to occur on any other
< Compositions, either nested within the current one, or within which the current one is nested (see
< <a class="reference internal" href="#composition-learning"><span class="std std-ref">Learning in a Composition</span></a> for a full description).</p>
---
> </ul>
> </div></blockquote>
> <blockquote id="composition-projections-arg">
> <div><ul>
> <li><dl>
> <dt><strong>projections</strong></dt><dd><p>adds the specified <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition;  this is equivalent to constructing the
> Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_projections" title="psyneulink.core.compositions.composition.Composition.add_projections"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_projections</span></code></a> method, and takes the same
> values as the <strong>projections</strong> argument of that method.  In general, this is not neded – default Projections
> are created for Pathways and/or Nodes added to the Composition using the methods described above; however
> it can be useful for custom configurations, including the implementation of specific Projection <a href="#id1"><span class="problematic" id="id2">`</span></a>matrices</p>
> <blockquote>
> <div><p>&lt;MappingProjection.matrix&gt;`.</p>
> </div></blockquote>
425a442,445
> </ul>
> </div></blockquote>
> <blockquote id="composition-controller-arg">
> <div><ul class="simple">
435a456
> </div></blockquote>
483,486c504,507
< <div><p>adds and a list of <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> and <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition,
< inserting a default Projection between any adjacent pair of Nodes for which one is not otherwise specified
< (or possibly a set of Projections if either Node is a Composition – see method documentation for details);
< returns the <a class="reference internal" href="Pathway.html"><span class="doc">Pathway</span></a> added to the Composition.</p>
---
> <div><p>adds and a list of <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> and <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition, inserting
> a default Projection between any adjacent set(s) of Nodes for which a Projection is not otherwise specified
> (see method documentation and <a class="reference internal" href="Pathway.html#pathway-specification"><span class="std std-ref">Pathway Specification</span></a> for additonal details); returns the <a class="reference internal" href="Pathway.html"><span class="doc">Pathway</span></a> added to
> the Composition.</p>
533c554
< <span id="id1"></span><h2>Composition Structure<a class="headerlink" href="#composition-structure" title="Permalink to this headline">¶</a></h2>
---
> <span id="id3"></span><h2>Composition Structure<a class="headerlink" href="#composition-structure" title="Permalink to this headline">¶</a></h2>
607,609c628,630
< outer Composition, are assigned <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> in addition to their other <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole" title="psyneulink.core.compositions.composition.NodeRole"><code class="xref any py py-class docutils literal notranslate"><span class="pre">roles</span></code></a> in the
< nested Composition.  The only difference between <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole.OUTPUT" title="psyneulink.core.compositions.composition.NodeRole.OUTPUT"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">OUTPUT</span></code></a> Nodes
< is whether their output is included in the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> attributes of the <em>outermost</em> Composition to which they project; this is determined by the
---
> outer Composition, are assigned <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> in addition to their other <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole" title="psyneulink.core.compositions.composition.NodeRole"><code class="xref any py py-class docutils literal notranslate"><span class="pre">roles</span></code></a> in the
> nested Composition.  The only difference between <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole.OUTPUT" title="psyneulink.core.compositions.composition.NodeRole.OUTPUT"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">OUTPUT</span></code></a> Nodes
> is whether their output is included in the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> attributes of the <em>outermost</em> Composition to which they project; this is determined by the
612c633
< <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes are <em>not</em> included in the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> or <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> for the outermost Composition to which they project (although they <em>are</em> still included
---
> <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes are <em>not</em> included in the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> or <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> for the outermost Composition to which they project (although they <em>are</em> still included
616c637
< <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.include_probes_in_output" title="psyneulink.core.compositions.composition.Composition.include_probes_in_output"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">include_probes_in_output</span></code></a> is True, then any <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes
---
> <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.include_probes_in_output" title="psyneulink.core.compositions.composition.Composition.include_probes_in_output"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">include_probes_in_output</span></code></a> is True, then any <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes
618,619c639,640
< the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> of the outermost Composition.
< <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes can be visualized, along with any Projections treated differently from those of
---
> the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" tit
...

See CI logs for the full diff.

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Jul 27, 2022

This pull request introduces 2 alerts and fixes 17 when merging 5f6875f into 7072684 - view on LGTM.com

new alerts:

  • 2 for Unused import

fixed alerts:

  • 12 for `__init__` method calls overridden method
  • 2 for Unused argument in a formatting call
  • 1 for Formatting string mixes implicitly and explicitly numbered fields
  • 1 for Missing call to `__init__` during object initialization
  • 1 for Wrong name for an argument in a class instantiation

@jvesely jvesely temporarily deployed to github-pages July 27, 2022 12:33 Inactive
@github-actions
Copy link

This PR causes the following changes to the html docs (ubuntu-latest-3.7-x64):

diff -r docs-base/BasicsAndPrimer.html docs-head/BasicsAndPrimer.html
308c308
< of computational models in neuroscience and psychology (see <a class="reference internal" href="mdf.html#module-psyneulink.core.globals.json" title="psyneulink.core.globals.json"><code class="xref any py py-mod docutils literal notranslate"><span class="pre">json</span></code></a>)</p>
---
> of computational models in neuroscience and psychology (see <code class="xref any docutils literal notranslate"><span class="pre">json</span></code>)</p>
diff -r docs-base/Composition.html docs-head/Composition.html
400a401
> <div><blockquote id="composition-pathways-arg">
403,405c404,410
< <dt><strong>nodes</strong></dt><dd><p>adds the specified <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> to the Composition;  this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_nodes" title="psyneulink.core.compositions.composition.Composition.add_nodes"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_nodes</span></code></a> method, and takes the same values as the
< <strong>nodes</strong> argument of that method.</p>
---
> <dt><strong>pathways</strong></dt><dd><p>adds one or more <a class="reference internal" href="#composition-pathways"><span class="std std-ref">Pathways</span></a> to the Composition; this is equivalent to constructing
> the Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method, and can use the
> same forms of specification as the <strong>pathways</strong> argument of that method (see <a class="reference internal" href="Pathway.html#pathway-specification"><span class="std std-ref">Pathway Specification</span></a> for
> additonal details). If any <a class="reference internal" href="#composition-learning-pathway"><span class="std std-ref">learning Pathways</span></a> are included, then the
> constructor’s <strong>disable_learning</strong> argument can be used to disable learning on those by default (though it
> will still allow learning to occur on any other Compositions, either nested within the current one,
> or within which the current one is nested (see <a class="reference internal" href="#composition-learning"><span class="std std-ref">Learning in a Composition</span></a> for a full description).</p>
408a414,417
> </ul>
> </div></blockquote>
> <blockquote id="composition-nodes-arg">
> <div><ul class="simple">
410,412c419,422
< <dt><strong>projections</strong></dt><dd><p>adds the specified <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition;  this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_projections" title="psyneulink.core.compositions.composition.Composition.add_projections"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_projections</span></code></a> method, and takes the same
< values as the <strong>projections</strong> argument of that method.</p>
---
> <dt><strong>nodes</strong></dt><dd><p>adds the specified <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> to the Composition;  this is equivalent to constructing the
> Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_nodes" title="psyneulink.core.compositions.composition.Composition.add_nodes"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_nodes</span></code></a> method, and takes the same values as the
> <strong>nodes</strong> argument of that method (note that this does <em>not</em> construct <a class="reference internal" href="Pathway.html"><span class="doc">Pathways</span></a> for the specified
> nodes; the <strong>pathways</strong> arg or  <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method must be used to do so).</p>
416,422c426,438
< <li><dl class="simple">
< <dt><strong>pathways</strong></dt><dd><p>adds one or more <a class="reference internal" href="#composition-pathways"><span class="std std-ref">Pathways</span></a> to the Composition; this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method, and can use the same forms
< of specification as the <strong>pathways</strong> argument of that method.  If any <a class="reference internal" href="#composition-learning-pathway"><span class="std std-ref">learning Pathways</span></a> are included, then the constructor’s <strong>disable_learning</strong> argument can be
< used to disable learning on those by default (though it will still allow learning to occur on any other
< Compositions, either nested within the current one, or within which the current one is nested (see
< <a class="reference internal" href="#composition-learning"><span class="std std-ref">Learning in a Composition</span></a> for a full description).</p>
---
> </ul>
> </div></blockquote>
> <blockquote id="composition-projections-arg">
> <div><ul>
> <li><dl>
> <dt><strong>projections</strong></dt><dd><p>adds the specified <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition;  this is equivalent to constructing the
> Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_projections" title="psyneulink.core.compositions.composition.Composition.add_projections"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_projections</span></code></a> method, and takes the same
> values as the <strong>projections</strong> argument of that method.  In general, this is not neded – default Projections
> are created for Pathways and/or Nodes added to the Composition using the methods described above; however
> it can be useful for custom configurations, including the implementation of specific Projection <a href="#id1"><span class="problematic" id="id2">`</span></a>matrices</p>
> <blockquote>
> <div><p>&lt;MappingProjection.matrix&gt;`.</p>
> </div></blockquote>
425a442,445
> </ul>
> </div></blockquote>
> <blockquote id="composition-controller-arg">
> <div><ul class="simple">
435a456
> </div></blockquote>
483,486c504,507
< <div><p>adds and a list of <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> and <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition,
< inserting a default Projection between any adjacent pair of Nodes for which one is not otherwise specified
< (or possibly a set of Projections if either Node is a Composition – see method documentation for details);
< returns the <a class="reference internal" href="Pathway.html"><span class="doc">Pathway</span></a> added to the Composition.</p>
---
> <div><p>adds and a list of <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> and <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition, inserting
> a default Projection between any adjacent set(s) of Nodes for which a Projection is not otherwise specified
> (see method documentation and <a class="reference internal" href="Pathway.html#pathway-specification"><span class="std std-ref">Pathway Specification</span></a> for additonal details); returns the <a class="reference internal" href="Pathway.html"><span class="doc">Pathway</span></a> added to
> the Composition.</p>
533c554
< <span id="id1"></span><h2>Composition Structure<a class="headerlink" href="#composition-structure" title="Permalink to this headline">¶</a></h2>
---
> <span id="id3"></span><h2>Composition Structure<a class="headerlink" href="#composition-structure" title="Permalink to this headline">¶</a></h2>
607,609c628,630
< outer Composition, are assigned <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> in addition to their other <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole" title="psyneulink.core.compositions.composition.NodeRole"><code class="xref any py py-class docutils literal notranslate"><span class="pre">roles</span></code></a> in the
< nested Composition.  The only difference between <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole.OUTPUT" title="psyneulink.core.compositions.composition.NodeRole.OUTPUT"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">OUTPUT</span></code></a> Nodes
< is whether their output is included in the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> attributes of the <em>outermost</em> Composition to which they project; this is determined by the
---
> outer Composition, are assigned <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> in addition to their other <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole" title="psyneulink.core.compositions.composition.NodeRole"><code class="xref any py py-class docutils literal notranslate"><span class="pre">roles</span></code></a> in the
> nested Composition.  The only difference between <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole.OUTPUT" title="psyneulink.core.compositions.composition.NodeRole.OUTPUT"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">OUTPUT</span></code></a> Nodes
> is whether their output is included in the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> attributes of the <em>outermost</em> Composition to which they project; this is determined by the
612c633
< <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes are <em>not</em> included in the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> or <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> for the outermost Composition to which they project (although they <em>are</em> still included
---
> <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes are <em>not</em> included in the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> or <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> for the outermost Composition to which they project (although they <em>are</em> still included
616c637
< <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.include_probes_in_output" title="psyneulink.core.compositions.composition.Composition.include_probes_in_output"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">include_probes_in_output</span></code></a> is True, then any <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes
---
> <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.include_probes_in_output" title="psyneulink.core.compositions.composition.Composition.include_probes_in_output"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">include_probes_in_output</span></code></a> is True, then any <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes
618,619c639,640
< the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> of the outermost Composition.
< <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes can be visualized, along with any Projections treated differently from those of
---
> the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" tit
...

See CI logs for the full diff.

@lgtm-com
Copy link
Contributor

lgtm-com bot commented Jul 27, 2022

This pull request introduces 2 alerts and fixes 17 when merging c863276 into 7072684 - view on LGTM.com

new alerts:

  • 2 for Unused import

fixed alerts:

  • 12 for `__init__` method calls overridden method
  • 2 for Unused argument in a formatting call
  • 1 for Formatting string mixes implicitly and explicitly numbered fields
  • 1 for Missing call to `__init__` during object initialization
  • 1 for Wrong name for an argument in a class instantiation

@github-actions
Copy link

This PR causes the following changes to the html docs (ubuntu-latest-3.7-x64):

diff -r docs-base/BasicsAndPrimer.html docs-head/BasicsAndPrimer.html
308c308
< of computational models in neuroscience and psychology (see <a class="reference internal" href="mdf.html#module-psyneulink.core.globals.json" title="psyneulink.core.globals.json"><code class="xref any py py-mod docutils literal notranslate"><span class="pre">json</span></code></a>)</p>
---
> of computational models in neuroscience and psychology (see <code class="xref any docutils literal notranslate"><span class="pre">json</span></code>)</p>
diff -r docs-base/Composition.html docs-head/Composition.html
400a401
> <div><blockquote id="composition-pathways-arg">
403,405c404,410
< <dt><strong>nodes</strong></dt><dd><p>adds the specified <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> to the Composition;  this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_nodes" title="psyneulink.core.compositions.composition.Composition.add_nodes"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_nodes</span></code></a> method, and takes the same values as the
< <strong>nodes</strong> argument of that method.</p>
---
> <dt><strong>pathways</strong></dt><dd><p>adds one or more <a class="reference internal" href="#composition-pathways"><span class="std std-ref">Pathways</span></a> to the Composition; this is equivalent to constructing
> the Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method, and can use the
> same forms of specification as the <strong>pathways</strong> argument of that method (see <a class="reference internal" href="Pathway.html#pathway-specification"><span class="std std-ref">Pathway Specification</span></a> for
> additonal details). If any <a class="reference internal" href="#composition-learning-pathway"><span class="std std-ref">learning Pathways</span></a> are included, then the
> constructor’s <strong>disable_learning</strong> argument can be used to disable learning on those by default (though it
> will still allow learning to occur on any other Compositions, either nested within the current one,
> or within which the current one is nested (see <a class="reference internal" href="#composition-learning"><span class="std std-ref">Learning in a Composition</span></a> for a full description).</p>
408a414,417
> </ul>
> </div></blockquote>
> <blockquote id="composition-nodes-arg">
> <div><ul class="simple">
410,412c419,422
< <dt><strong>projections</strong></dt><dd><p>adds the specified <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition;  this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_projections" title="psyneulink.core.compositions.composition.Composition.add_projections"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_projections</span></code></a> method, and takes the same
< values as the <strong>projections</strong> argument of that method.</p>
---
> <dt><strong>nodes</strong></dt><dd><p>adds the specified <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> to the Composition;  this is equivalent to constructing the
> Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_nodes" title="psyneulink.core.compositions.composition.Composition.add_nodes"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_nodes</span></code></a> method, and takes the same values as the
> <strong>nodes</strong> argument of that method (note that this does <em>not</em> construct <a class="reference internal" href="Pathway.html"><span class="doc">Pathways</span></a> for the specified
> nodes; the <strong>pathways</strong> arg or  <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method must be used to do so).</p>
416,422c426,438
< <li><dl class="simple">
< <dt><strong>pathways</strong></dt><dd><p>adds one or more <a class="reference internal" href="#composition-pathways"><span class="std std-ref">Pathways</span></a> to the Composition; this is equivalent to constructing the
< Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_pathways" title="psyneulink.core.compositions.composition.Composition.add_pathways"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_pathways</span></code></a> method, and can use the same forms
< of specification as the <strong>pathways</strong> argument of that method.  If any <a class="reference internal" href="#composition-learning-pathway"><span class="std std-ref">learning Pathways</span></a> are included, then the constructor’s <strong>disable_learning</strong> argument can be
< used to disable learning on those by default (though it will still allow learning to occur on any other
< Compositions, either nested within the current one, or within which the current one is nested (see
< <a class="reference internal" href="#composition-learning"><span class="std std-ref">Learning in a Composition</span></a> for a full description).</p>
---
> </ul>
> </div></blockquote>
> <blockquote id="composition-projections-arg">
> <div><ul>
> <li><dl>
> <dt><strong>projections</strong></dt><dd><p>adds the specified <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition;  this is equivalent to constructing the
> Composition and then calling its <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.add_projections" title="psyneulink.core.compositions.composition.Composition.add_projections"><code class="xref any py py-meth docutils literal notranslate"><span class="pre">add_projections</span></code></a> method, and takes the same
> values as the <strong>projections</strong> argument of that method.  In general, this is not neded – default Projections
> are created for Pathways and/or Nodes added to the Composition using the methods described above; however
> it can be useful for custom configurations, including the implementation of specific Projection <a href="#id1"><span class="problematic" id="id2">`</span></a>matrices</p>
> <blockquote>
> <div><p>&lt;MappingProjection.matrix&gt;`.</p>
> </div></blockquote>
425a442,445
> </ul>
> </div></blockquote>
> <blockquote id="composition-controller-arg">
> <div><ul class="simple">
435a456
> </div></blockquote>
483,486c504,507
< <div><p>adds and a list of <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> and <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition,
< inserting a default Projection between any adjacent pair of Nodes for which one is not otherwise specified
< (or possibly a set of Projections if either Node is a Composition – see method documentation for details);
< returns the <a class="reference internal" href="Pathway.html"><span class="doc">Pathway</span></a> added to the Composition.</p>
---
> <div><p>adds and a list of <a class="reference internal" href="#composition-nodes"><span class="std std-ref">Nodes</span></a> and <a class="reference internal" href="Projection.html"><span class="doc">Projections</span></a> to the Composition, inserting
> a default Projection between any adjacent set(s) of Nodes for which a Projection is not otherwise specified
> (see method documentation and <a class="reference internal" href="Pathway.html#pathway-specification"><span class="std std-ref">Pathway Specification</span></a> for additonal details); returns the <a class="reference internal" href="Pathway.html"><span class="doc">Pathway</span></a> added to
> the Composition.</p>
533c554
< <span id="id1"></span><h2>Composition Structure<a class="headerlink" href="#composition-structure" title="Permalink to this headline">¶</a></h2>
---
> <span id="id3"></span><h2>Composition Structure<a class="headerlink" href="#composition-structure" title="Permalink to this headline">¶</a></h2>
607,609c628,630
< outer Composition, are assigned <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> in addition to their other <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole" title="psyneulink.core.compositions.composition.NodeRole"><code class="xref any py py-class docutils literal notranslate"><span class="pre">roles</span></code></a> in the
< nested Composition.  The only difference between <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole.OUTPUT" title="psyneulink.core.compositions.composition.NodeRole.OUTPUT"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">OUTPUT</span></code></a> Nodes
< is whether their output is included in the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> attributes of the <em>outermost</em> Composition to which they project; this is determined by the
---
> outer Composition, are assigned <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> in addition to their other <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole" title="psyneulink.core.compositions.composition.NodeRole"><code class="xref any py py-class docutils literal notranslate"><span class="pre">roles</span></code></a> in the
> nested Composition.  The only difference between <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.NodeRole.OUTPUT" title="psyneulink.core.compositions.composition.NodeRole.OUTPUT"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">OUTPUT</span></code></a> Nodes
> is whether their output is included in the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> attributes of the <em>outermost</em> Composition to which they project; this is determined by the
612c633
< <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes are <em>not</em> included in the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> or <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> for the outermost Composition to which they project (although they <em>are</em> still included
---
> <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes are <em>not</em> included in the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> or <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> for the outermost Composition to which they project (although they <em>are</em> still included
616c637
< <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.include_probes_in_output" title="psyneulink.core.compositions.composition.Composition.include_probes_in_output"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">include_probes_in_output</span></code></a> is True, then any <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes
---
> <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.include_probes_in_output" title="psyneulink.core.compositions.composition.Composition.include_probes_in_output"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">include_probes_in_output</span></code></a> is True, then any <a class="reference internal" href="#id26" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes
618,619c639,640
< the <a class="reference internal" href="#id19" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" title="psyneulink.core.compositions.composition.Composition.results"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">results</span></code></a> of the outermost Composition.
< <a class="reference internal" href="#id24" title="psyneulink.core.compositions.composition.NodeRole.PROBE"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">PROBE</span></code></a> Nodes can be visualized, along with any Projections treated differently from those of
---
> the <a class="reference internal" href="#id21" title="psyneulink.core.compositions.composition.Composition.output_values"><code class="xref any py py-attr docutils literal notranslate"><span class="pre">output_values</span></code></a> and <a class="reference internal" href="#psyneulink.core.compositions.composition.Composition.results" tit
...

See CI logs for the full diff.

@jvesely jvesely temporarily deployed to github-pages July 27, 2022 15:24 Inactive
@lgtm-com
Copy link
Contributor

lgtm-com bot commented Jul 27, 2022

This pull request introduces 2 alerts and fixes 17 when merging 0be359f into 7072684 - view on LGTM.com

new alerts:

  • 2 for Unused import

fixed alerts:

  • 12 for `__init__` method calls overridden method
  • 2 for Unused argument in a formatting call
  • 1 for Formatting string mixes implicitly and explicitly numbered fields
  • 1 for Missing call to `__init__` during object initialization
  • 1 for Wrong name for an argument in a class instantiation

@kmantel kmantel merged commit d1c854d into master Jul 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants