3162e475ad96caa7e62a6351544fac23e148ab30,niftynet/engine/sampler_selective.py,,rand_choice_coordinates,#Any#Any#Any#Any#Any#,196

Before Change


    candidates_indices = np.vstack(np.where(candidates == 1)).T
    list_indices = np.arange(len(candidates_indices))
    print(np.sum(candidates), list_indices)
    print(len(candidates_indices), candidates_indices.shape)
    np.random.shuffle(list_indices)
    half_max_spatial_win = np.floor(max_spatial_win / 2.0)
    for i in range(0, n_samples):
        indices_to_add = candidates_indices[list_indices[i]]

After Change


        indices_to_add = candidates_indices[list_indices[i]]
        print(max_coords.shape, indices_to_add)
        for s in range(0, N_SPATIAL):
            max_coords[i, s] = indices_to_add[s] - np.floor(
                spatial_win_sizes[0]/2)[s]
    // for i in range(0, N_SPATIAL):
    //     assert uniq_spatial_size[i] >= max_spatial_win[i], \
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: NifTK/NiftyNet
Commit Name: 3162e475ad96caa7e62a6351544fac23e148ab30
Time: 2017-09-16
Author: carole.sudre.12@ucl.ac.uk
File Name: niftynet/engine/sampler_selective.py
Class Name:
Method Name: rand_choice_coordinates


Project Name: dmnfarrell/pandastable
Commit Name: a00159cee56a3a8613292b1400c397207d8ae2db
Time: 2015-07-25
Author: farrell.damien@gmail.com
File Name: pandastable/plotting.py
Class Name: PlotViewer
Method Name: scatter


Project Name: biotite-dev/biotite
Commit Name: c9c407951adfd5c101a1875e2761db98eb1f8fa8
Time: 2020-08-18
Author: patrick.kunzm@gmail.com
File Name: doc/examples/scripts/sequence/quality_control.py
Class Name:
Method Name: