Skip to content

Add batch neighbor counting helper #38

Open
@dburkhardt

Description

@dburkhardt

Code from Scott.

batch_mix_mat = np.array([[G.kernel[sample_idx==batch_i,:][:,sample_idx==batch_j].sum()
                 for batch_i in np.unique(sample_idx)]
                 for batch_j in np.unique(sample_idx)])
batch_mix_mat = batch_mix_mat / np.sum(batch_mix_mat, axis=1)[:,None]
batch_mix_mat```

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions