e4d313478124e00a931ec40ab25643accad88641,beancount_import/source/generic_importer_source.py,ImporterSource,prepare,#ImporterSource#Any#Any#,55
Before Change
for entry in f_entries:
hash_ = self._hash_entry(entry, frozenset(["filename","lineno"]))
// skip the existing entries from other statements
if hash_ in entries: continue
// If the entry exists in the journal, skip
if self._is_existing(journal, entry): continue
// add importer name as sorce description to source postings
self._add_description(entry)
After Change
n = len(entries[hash_])
entries[hash_].extend(hashed_entries[hash_][n:])
uncleared_entries = defaultdict(list)
for hash_ in entries:
// number of matching cleared entries in journal
n = len(similar_entries_in_journal(entries[hash_][0],
journal.entries,
self.comparator))
// If journal has n cleared entries for this hash, pick remaining
for entry in entries[hash_][n:]:
// add importer name as sorce description to source postings
self._add_description(entry)
// balance amount
self.balance_amounts(entry)
uncleared_entries[hash_].append(entry)
results.add_pending_entries(
[ImportResult(entry.date, [entry], None)
for entry in itertools.chain.from_iterable(uncleared_entries.values())
]
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 9
Instances Project Name: jbms/beancount-import
Commit Name: e4d313478124e00a931ec40ab25643accad88641
Time: 2020-08-06
Author: dumbpyx@gmail.com
File Name: beancount_import/source/generic_importer_source.py
Class Name: ImporterSource
Method Name: prepare
Project Name: pytorch/fairseq
Commit Name: d47067937abacfe87f2963adca8daeada3c631fe
Time: 2020-09-10
Author: bhosale.shruti18@gmail.com
File Name: fairseq/optim/fp16_optimizer.py
Class Name: _FP16OptimizerMixin
Method Name: _sync_fp32_params_to_fp16
Project Name: jbms/beancount-import
Commit Name: e4d313478124e00a931ec40ab25643accad88641
Time: 2020-08-06
Author: dumbpyx@gmail.com
File Name: beancount_import/source/generic_importer_source.py
Class Name: ImporterSource
Method Name: prepare
Project Name: pytorch/fairseq
Commit Name: d47067937abacfe87f2963adca8daeada3c631fe
Time: 2020-09-10
Author: bhosale.shruti18@gmail.com
File Name: fairseq/optim/fp16_optimizer.py
Class Name: _FP16OptimizerMixin
Method Name: _sync_fp16_grads_to_fp32