Beispiel #1
0
 def _float_feature(value):
     """Wrapper for inserting float features into Example proto."""
     if not isinstance(value, list):
         value = [value]
     return of_record.Feature(float_list=of_record.FloatList(value=value))
Beispiel #2
0
def float_feature(value):
    if not isinstance(value, (list, tuple)):
        value = [value]
    return ofrecord.Feature(float_list=ofrecord.FloatList(value=value))