예제 #1
0
 def set_data_attr(self, data):
   default_img = params.Image(
       channels=3,
       frames=1,
       raw_height=28,
       raw_width=28,
       output_height=28,
       output_width=28,
       preprocessing_method='cifarnet')
   data.entry_path = self.data_dir + '/' + data.entry_path
   data.set_image([default_img])
   data.set_entry_attr((str, int), (True, False))
   data.set_label(num_classes=1, span=10, scale=True)
   return data
예제 #2
0
 def set_data_attr(self, data):
     default_img = params.Image(channels=3,
                                frames=1,
                                raw_height=128,
                                raw_width=128,
                                output_height=128,
                                output_width=128,
                                preprocessing_method='vae.kinship',
                                gray=False)
     data.entry_path = self.data_dir + '/' + data.entry_path
     data.set_image([default_img, default_img])
     data.set_entry_attr(entry_dtype=(str, str, int, int),
                         entry_check=(True, True, False, False))
     data.set_label(num_classes=1)
     return data