088b7601d2a21eb092150ae5f4070a8ab52306f3,qucumber/observables/pauli.py,SigmaX,apply,#SigmaX#Any#Any#,53

Before Change



        for i in range(samples.shape[-1]):  // sum over spin sites
            self._flip_spin(i, samples)  // flip the spin at site i
            psi_ratios[:, :] += nn_states.psi(samples)  // TODO: do division here
            self._flip_spin(i, samples)  // flip it back

        // TODO: divide psi_-i / psi_i using complex math

After Change



            self._flip_spin(i, samples)  // flip it back

        return cplx.elementwise_norm(psi_ratio_sum).div_(samples.shape[-1])
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: PIQuIL/QuCumber
Commit Name: 088b7601d2a21eb092150ae5f4070a8ab52306f3
Time: 2018-08-18
Author: emerali@users.noreply.github.com
File Name: qucumber/observables/pauli.py
Class Name: SigmaX
Method Name: apply


Project Name: inferno-pytorch/inferno
Commit Name: aa0c4bfdeb0ebeaf5a1d80e6415e7def17270737
Time: 2017-08-25
Author: nasim.rahaman@iwr.uni-heidelberg.de
File Name: inferno/extensions/metrics/categorical.py
Class Name: IOU
Method Name: forward


Project Name: open-mmlab/mmdetection
Commit Name: cd0d37ccb398b7e80dd7af06925246e133d8178c
Time: 2019-12-18
Author: yhcao6@gmail.com
File Name: mmdet/apis/train.py
Class Name:
Method Name: parse_losses