Skip to content

Minor improvements #2

@jdrugo

Description

@jdrugo

I suggest a range of minor improvements to the current version of the InfluenceCalculator class:

  • Add count_thresh=5 argument to __init__ that in turn is provided to _load_sql_data to support customized thresholds on the synapse counts.
  • Clarify in docstring possible values to syn_weight_measure argument of _create_sparse_W method.
  • Clarify in docstring that the silenced_neurons argument of the calculate_influence method needs to be a list or numpy array of neuron_ids rather than a pandas table, and update the usage example accordingly.
  • Eventually turn the _solve_lin_system method into a static method, as it doesn't seem to modify any class variables.
  • Ensure that the _normalize_W method directly modifies W_norm, such that it doesn't need to be returned, and that W_norm = self._normalize_W(W_norm) can be replaced by a simple call to self._normalize_W(W_norm).
  • To clarify that the _set_columns_to_zero expects silenced_neurons to be W matrix indices rather than neuron_ids, rename argument to silenced_W_idcs and update the method's docstring to reflect that.

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions