[GitHub] rahul003 commented on a change in pull request #11027: Add standard ResNet data augmentation for ImageRecordIter

2018-07-19 Thread GitBox
rahul003 commented on a change in pull request #11027: Add standard ResNet data 
augmentation for ImageRecordIter
URL: https://github.com/apache/incubator-mxnet/pull/11027#discussion_r203620309
 
 

 ##
 File path: example/image-classification/common/data.py
 ##
 @@ -63,6 +65,20 @@ def add_data_aug_args(parser):
  help='max ratio to scale')
 aug.add_argument('--min-random-scale', type=float, default=1,
  help='min ratio to scale, should >= img_size/input_shape. 
otherwise use --pad-size')
+aug.add_argument('--max-random-area', type=float, default=1,
+ help='max area to crop in random resized crop, whose 
range is [0, 1]')
+aug.add_argument('--min-random-area', type=float, default=1,
+ help='min area to crop in random resized crop, whose 
range is [0, 1]')
+aug.add_argument('--brightness', type=float, default=0,
 
 Review comment:
   @DickJC123 Hi Dick, I'm fixing these issues in 
https://github.com/apache/incubator-mxnet/pull/11533 


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rahul003 commented on a change in pull request #11027: Add standard ResNet data augmentation for ImageRecordIter

2018-06-08 Thread GitBox
rahul003 commented on a change in pull request #11027: Add standard ResNet data 
augmentation for ImageRecordIter
URL: https://github.com/apache/incubator-mxnet/pull/11027#discussion_r194191844
 
 

 ##
 File path: example/image-classification/common/data.py
 ##
 @@ -63,6 +65,20 @@ def add_data_aug_args(parser):
  help='max ratio to scale')
 aug.add_argument('--min-random-scale', type=float, default=1,
  help='min ratio to scale, should >= img_size/input_shape. 
otherwise use --pad-size')
+aug.add_argument('--max-random-area', type=float, default=1,
+ help='max area to crop in random resized crop, whose 
range is [0, 1]')
+aug.add_argument('--min-random-area', type=float, default=1,
+ help='min area to crop in random resized crop, whose 
range is [0, 1]')
+aug.add_argument('--brightness', type=float, default=0,
 
 Review comment:
   How about a function like the set_aug_level with the defaults set for 
resnet, but that function is not automatically called? 
   My only concern was that we don't have a good source (for users not using 
GluonCv, on a good set of starting params). Your point also makes sense, so am 
not too strongly opinionated about this. 


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rahul003 commented on a change in pull request #11027: Add standard ResNet data augmentation for ImageRecordIter

2018-06-08 Thread GitBox
rahul003 commented on a change in pull request #11027: Add standard ResNet data 
augmentation for ImageRecordIter
URL: https://github.com/apache/incubator-mxnet/pull/11027#discussion_r194191844
 
 

 ##
 File path: example/image-classification/common/data.py
 ##
 @@ -63,6 +65,20 @@ def add_data_aug_args(parser):
  help='max ratio to scale')
 aug.add_argument('--min-random-scale', type=float, default=1,
  help='min ratio to scale, should >= img_size/input_shape. 
otherwise use --pad-size')
+aug.add_argument('--max-random-area', type=float, default=1,
+ help='max area to crop in random resized crop, whose 
range is [0, 1]')
+aug.add_argument('--min-random-area', type=float, default=1,
+ help='min area to crop in random resized crop, whose 
range is [0, 1]')
+aug.add_argument('--brightness', type=float, default=0,
 
 Review comment:
   How about a function like the set_aug_level with the defaults set for 
resnet, but that function is not automatically called? 
   My only concern was that we don't have a good source (for users not using 
GluonCv, on a good set of starting params). Your point also makes sense, don't 
have a strong opinion on this. 


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rahul003 commented on a change in pull request #11027: Add standard ResNet data augmentation for ImageRecordIter

2018-06-08 Thread GitBox
rahul003 commented on a change in pull request #11027: Add standard ResNet data 
augmentation for ImageRecordIter
URL: https://github.com/apache/incubator-mxnet/pull/11027#discussion_r194190513
 
 

 ##
 File path: example/image-classification/common/data.py
 ##
 @@ -120,6 +136,7 @@ def get_rec_iter(args, kv=None):
 else:
 (rank, nworker) = (0, 1)
 rgb_mean = [float(i) for i in args.rgb_mean.split(',')]
+random_resized_crop = args.random_resized_crop is not None
 
 Review comment:
   Also, for uniformity with random-crop and random-mirror we might want to 
random-resized-crop be of type int 


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rahul003 commented on a change in pull request #11027: Add standard ResNet data augmentation for ImageRecordIter

2018-06-08 Thread GitBox
rahul003 commented on a change in pull request #11027: Add standard ResNet data 
augmentation for ImageRecordIter
URL: https://github.com/apache/incubator-mxnet/pull/11027#discussion_r194186252
 
 

 ##
 File path: example/image-classification/common/data.py
 ##
 @@ -120,6 +136,7 @@ def get_rec_iter(args, kv=None):
 else:
 (rank, nworker) = (0, 1)
 rgb_mean = [float(i) for i in args.rgb_mean.split(',')]
+random_resized_crop = args.random_resized_crop is not None
 
 Review comment:
   Wouldn't args.random_resized_crop never be None? action='store_true' means 
if not passed it is set by default to false


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rahul003 commented on a change in pull request #11027: Add standard ResNet data augmentation for ImageRecordIter

2018-06-08 Thread GitBox
rahul003 commented on a change in pull request #11027: Add standard ResNet data 
augmentation for ImageRecordIter
URL: https://github.com/apache/incubator-mxnet/pull/11027#discussion_r194184683
 
 

 ##
 File path: example/image-classification/common/data.py
 ##
 @@ -63,6 +65,20 @@ def add_data_aug_args(parser):
  help='max ratio to scale')
 aug.add_argument('--min-random-scale', type=float, default=1,
  help='min ratio to scale, should >= img_size/input_shape. 
otherwise use --pad-size')
+aug.add_argument('--max-random-area', type=float, default=1,
+ help='max area to crop in random resized crop, whose 
range is [0, 1]')
+aug.add_argument('--min-random-area', type=float, default=1,
+ help='min area to crop in random resized crop, whose 
range is [0, 1]')
+aug.add_argument('--brightness', type=float, default=0,
 
 Review comment:
   I think it would be better to set defaults to the values we know work well, 
so that this script is runnable easily. Especially since we no longer set the 
aug level in train_imagenet.py
   


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rahul003 commented on a change in pull request #11027: Add standard ResNet data augmentation for ImageRecordIter

2018-06-08 Thread GitBox
rahul003 commented on a change in pull request #11027: Add standard ResNet data 
augmentation for ImageRecordIter
URL: https://github.com/apache/incubator-mxnet/pull/11027#discussion_r194184683
 
 

 ##
 File path: example/image-classification/common/data.py
 ##
 @@ -63,6 +65,20 @@ def add_data_aug_args(parser):
  help='max ratio to scale')
 aug.add_argument('--min-random-scale', type=float, default=1,
  help='min ratio to scale, should >= img_size/input_shape. 
otherwise use --pad-size')
+aug.add_argument('--max-random-area', type=float, default=1,
+ help='max area to crop in random resized crop, whose 
range is [0, 1]')
+aug.add_argument('--min-random-area', type=float, default=1,
+ help='min area to crop in random resized crop, whose 
range is [0, 1]')
+aug.add_argument('--brightness', type=float, default=0,
 
 Review comment:
   I think it would be better to set defaults to the values we know work well


This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services


[GitHub] rahul003 commented on a change in pull request #11027: Add standard ResNet data augmentation for ImageRecordIter

2018-05-25 Thread GitBox
rahul003 commented on a change in pull request #11027: Add standard ResNet data 
augmentation for ImageRecordIter
URL: https://github.com/apache/incubator-mxnet/pull/11027#discussion_r191026394
 
 

 ##
 File path: src/io/image_aug_default.cc
 ##
 @@ -104,16 +127,37 @@ struct DefaultImageAugmentParam : public 
dmlc::Parameter