72010aaac0c812a833a90e26b580bd57b6741a1a,pixyz/distributions/distributions.py,DistGraph,sample,#DistGraph#Any#Any#Any#Any#Any#,133
Before Change
return_all=False, reparam=reparam))
// ignore return_all because overriding is now under control.
if not(set(x_dict.keys()) >= set(self.input_var)):
raise ValueError("Input keys are not valid, expected {} but got {}.".format(set(self.input_var),
set(x_dict.keys())))
values = get_dict_values(x_dict, self.input_var, return_dict=True)
for var, dist in self.node_distributions(sorted=True):
if any(cond not in values for cond in self.graph.pred[var]):
After Change
return_all=False, reparam=reparam))
// ignore return_all because overriding is now under control.
if not(set(x_dict.keys()) >= set(self.input_var)):
raise ValueError(f"Input keys are not valid, expected {set(self.input_var)} but got {set(x_dict.keys())}.")
values = get_dict_values(x_dict, self.input_var, return_dict=True)
for var, dist in self.node_distributions(sorted=True):
if any(cond not in values for cond in self.graph.pred[var]):
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 7
Instances Project Name: masa-su/pixyz
Commit Name: 72010aaac0c812a833a90e26b580bd57b6741a1a
Time: 2020-07-06
Author: kaneko@weblab.t.u-tokyo.ac.jp
File Name: pixyz/distributions/distributions.py
Class Name: DistGraph
Method Name: sample
Project Name: masa-su/pixyz
Commit Name: 72010aaac0c812a833a90e26b580bd57b6741a1a
Time: 2020-07-06
Author: kaneko@weblab.t.u-tokyo.ac.jp
File Name: pixyz/distributions/distributions.py
Class Name: DistributionBase
Method Name: set_dist
Project Name: masa-su/pixyz
Commit Name: 72010aaac0c812a833a90e26b580bd57b6741a1a
Time: 2020-07-06
Author: kaneko@weblab.t.u-tokyo.ac.jp
File Name: pixyz/distributions/distributions.py
Class Name: DistGraph
Method Name: get_log_prob