Hi,
Here is a code sample that generate the convolution parameters from the minimal set of parameters:
import math
import torch

nf = 3
ks = 3

diff_chan_params = torch.rand(nf*(nf-1)/2, ks, ks)
same_chan_params = torch.rand(int(math.ceil(float(nf)/2)), ks, ks)
print("learnable parameters")
print(diff_chan_params)
print(same_chan_params)

def get_params(chan_in, chan_out):
    if chan_in == chan_out:
        s = same_chan_params[chan_in/2]
        if chan_in%2 == 0:
            triang = s.triu()
        else:
            triang = s.tril()
        return triang + triang.t()
    small_idx = min(chan_in, chan_out)
    large_idx = max(chan_in, chan_out)
    lin_idx  = small_idx + large_idx * (large_idx - 1) / 2
    param = diff_chan_params[lin_idx]
    if chan_in < chan_out:
        param = param.t()
    return param

curr_idx = 0
conv_params = []
for out_c in range(nf):
    tmp = []
    for in_c in range(nf):
        tmp.append(get_params(in_c, out_c))
    conv_params.append(torch.stack(tmp, 0))
full_params = torch.stack(conv_params, 0)
print("conv parameters")
print(full_params)