Skip to content

Question: Where does the weight transfer happen? #207

Description

@cowolff

Quick question regarding this tutorial:
https://sinabs.readthedocs.io/en/v1.2.10/tutorials/weight_transfer_mnist.html
I understand that the model conversion happens in this line:

sinabs_model = from_model(
    ann, input_shape=input_shape, add_spiking_output=True, synops=False, num_timesteps=num_timesteps
)

What I don't understand is, where does the weight conversion from the ANN to the SNN actually happen?
As far as I understand those 3 files from_torch.py, conversion.py and network.py the model is first recreated in the same "shape" as the original model, just with spiking layers and then handed over to the network class in combination with the old model. This is then returned to the user. Still, I don't understand, where the weights from the ANN are actually transferred to the SNN?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions