77a010bc4ec97a10dd9de3060744157bedb0e079,ludwig/utils/strings_utils.py,,load_vocabulary,#Any#,76
Before Change
def load_vocabulary(vocab_file):
with open(vocab_file, "r") as f:
return [line.strip() for line in f]
def create_vocabulary(
data,
After Change
for line in f:
line = line.strip()
if " " in line:
line = line.split(" ")[0]
vocabulary.append(line)
return vocabulary
//return [line.strip() for line in f]
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 3
Instances Project Name: uber/ludwig
Commit Name: 77a010bc4ec97a10dd9de3060744157bedb0e079
Time: 2019-10-10
Author: piero@uber.com
File Name: ludwig/utils/strings_utils.py
Class Name:
Method Name: load_vocabulary
Project Name: evilsocket/pwnagotchi
Commit Name: 90b0e10e81a5a0e03753715ec1034278bdd5f600
Time: 2019-10-07
Author: evilsocket@gmail.com
File Name: pwnagotchi/plugins/default/api.py
Class Name:
Method Name: parse_pcap
Project Name: maxpumperla/elephas
Commit Name: c9aca7047d5d556d539e15e9f1694eafb4c1d931
Time: 2021-01-12
Author: danielenricocahall@gmail.com
File Name: elephas/parameter/client.py
Class Name: SocketClient
Method Name: get_parameters