fc1952ad8d675e930bbd58757a1c5a4eeadaa269,dit/samplespace.py,SampleSpace,__init__,#SampleSpace#Any#Any#,59

Before Change



    
    def __init__(self, samplespace, product=product):
        self._samplespace = list(samplespace)
        self._length = len(samplespace)
        self._product = product
        self._outcome_length = len(samplespace[0])
        self._outcome_class = samplespace[0].__class__
        self._outcome_ctor = get_outcome_ctor(self._outcome_class)

        // Store a set for O(1) lookup.
        self._set = set(samplespace)

    def __len__(self):
        return self._length

After Change


        "is_joint": True,
    }

    def __init__(self, samplespace, product=None):
        super(SampleSpace, self).__init__(samplespace)

        self._outcome_length = len(samplespace[0])
        self._outcome_class = samplespace[0].__class__
        self._outcome_ctor = get_outcome_ctor(self._outcome_class)
        // Since we have access to an outcome, we determine a product from it.
        if product is None:
            self._product = get_product_func(self._outcome_class)
        else:
            self._product = product

    def coalesce(self, rvs, extract=False):
        
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 13

Instances


Project Name: dit/dit
Commit Name: fc1952ad8d675e930bbd58757a1c5a4eeadaa269
Time: 2014-04-13
Author: chebee7i@gmail.com
File Name: dit/samplespace.py
Class Name: SampleSpace
Method Name: __init__


Project Name: pantsbuild/pants
Commit Name: 3f5e994767718a930681d75bd59154525b02cd18
Time: 2014-01-19
Author: benjyw@gmail.com
File Name: src/python/twitter/pants/python/thrift_builder.py
Class Name: PythonThriftBuilder
Method Name: __init__


Project Name: pantsbuild/pants
Commit Name: 0a6edd21b9ab29a1f733b90ff15092e7a03f665d
Time: 2014-01-15
Author: jsirois@twitter.com
File Name: src/python/twitter/pants/python/thrift_builder.py
Class Name: PythonThriftBuilder
Method Name: __init__