text_plain_output_1.png
import tensorflow as tf

import tensorflow as tf
import numpy as np
video_lvl_record = '../input/video_level/train-1.tfrecord'
frame_lvl_record = '../input/frame_level/train-1.tfrecord'
vid_ids = []
labels = []
mean_rgb = []
mean_audio = []
for example in tf.python_io.tf_record_iterator(video_lvl_record):
    tf_example = tf.train.Example.FromString(example)
    vid_ids.append(tf_example.features.feature['video_id'].bytes_list.value[0].decode(encoding='UTF-8'))
    labels.append(tf_example.features.feature['labels'].int64_list.value)
    mean_rgb.append(tf_example.features.feature['mean_rgb'].float_list.value)
    mean_audio.append(tf_example.features.feature['mean_audio'].float_list.value)

test = labels[:5]
label_test = [item for sublist in test for item in sublist]
label_test