3be1154314111df8cd327a321fe3d68e7b661c68,tensorflow_datasets/text/pg19.py,Pg19,_generate_examples,#Pg19#Any#Any#,105
Before Change
def _generate_examples(self, filepaths, metadata):
Yields examples.
metadata_dict = collections.defaultdict(list)
for row in metadata:
features = row.split(",")
metadata_dict["book_id"].append(int(features[0]))
metadata_dict["book_title"].append(str(features[1]))
After Change
book_id = metadata[index][0]
print("<-----CHARLES----->", file)
book_data = metadata[index][1]
print(book_data)
// book_data = metadata[int(book_id)]
with tf.io.gfile.GFile(file, "r") as f:
text = f.read().strip()
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 4
Instances
Project Name: tensorflow/datasets
Commit Name: 3be1154314111df8cd327a321fe3d68e7b661c68
Time: 2020-05-29
Author: charlespatel07@gmail.com
File Name: tensorflow_datasets/text/pg19.py
Class Name: Pg19
Method Name: _generate_examples
Project Name: markovmodel/PyEMMA
Commit Name: b69a4513d333266b032e11f9563d6bd14830aa86
Time: 2018-06-21
Author: m.scherer@fu-berlin.de
File Name: conftest.py
Class Name:
Method Name: pytest_collection_modifyitems
Project Name: reinforceio/tensorforce
Commit Name: e5378bb14d019f756361775457f734801e51bbb4
Time: 2017-03-04
Author: mi.schaarschmidt@gmail.com
File Name: tensorforce/agents/distributed_agent.py
Class Name: Batch
Method Name: add_observation