608fff2119f21191352ddf5d96eb82fc1ab099b0,dit/utils/misc.py,,partitions,#,370
Before Change
yield ()
return
for i in xrange(2**len(set_) / 2):
parts = [set(), set() ]
for item in set_:
parts[i&1].add(item)
i >>= 1
for b in partitions(parts[1]):
yield (parts[0],) + b
def partitions(set_):
Generates partitions of elements in `set_".
After Change
else:
for partition in partitions1( seq ):
partition = frozenset( map(frozenset, partition) )
yield partition
def ordered_partitions(seq, tuples=False):
In pattern: SUPERPATTERN
Frequency: 4
Non-data size: 4
Instances Project Name: dit/dit
Commit Name: 608fff2119f21191352ddf5d96eb82fc1ab099b0
Time: 2013-02-25
Author: chebee7i@gmail.com
File Name: dit/utils/misc.py
Class Name:
Method Name: partitions
Project Name: CyberReboot/NetworkML
Commit Name: cd83fed56a184063215f932ef768f8834328654c
Time: 2020-04-01
Author: josh@vandervecken.com
File Name: networkml/featurizers/funcs/host.py
Class Name: HostBase
Method Name: HostBase_1
Project Name: dit/dit
Commit Name: 146f5ddd1ac881fbebdeff83c0be0322bf7e1d74
Time: 2013-09-27
Author: chebee7i@gmail.com
File Name: dit/math/sigmaalgebra.py
Class Name:
Method Name: is_sigma_algebra__brute
Project Name: dit/dit
Commit Name: 146f5ddd1ac881fbebdeff83c0be0322bf7e1d74
Time: 2013-09-27
Author: chebee7i@gmail.com
File Name: dit/math/sigmaalgebra.py
Class Name:
Method Name: sets2matrix