On Wed, Jan 2, 2013 at 10:47 AM, Brian Schott <[email protected]> wrote:
> Regarding "Why?", I was training a neural net to recognize 13x13
> images and I wanted to create slightly imprecise images to improve the
> net, so I generated randomized compressions. Does that explain it?
With this statement of purpose, other valid choices seem to include:
1. Pick a random pixel for each choice from 2 by 2 pixel region.
sample1=: 3 : 'wind (?@4: { ,);._3"2 y'
sample1^:2 specimen
2. Move the random choice out of sample
sample2=: 4 : 'wind x&{@,;._3"2 y'
(?@4: sample2 ])^:2 specimen
so I still do not know why you made the choice you did, nor whether it
was the right choice for your purposes.
> Now my neural net is trained and I want to just compress 52x52 images
> to 13x13 and am waffling on whether the filtering process now should
> be similarly random or should be based on something like the "median
> filter" value of the 4x4 subregion like Cliff Reiter does. Having
> looked at the matrix and vector C routines supplied by Apple, which do
> not offer a median filter-like option, I am leaning toward the type of
> compression I mentioned in a previous message in this thread named
> "vDSP_vcmprs". I am still trying to figure out its use, though, and
> hoping that it use of "stride" will enable me to compress in
> checkboard sub regions of 2x2 or 4x4. As to the choice of which item
> to select in each region, I am still waffling on whether or not to
> choose randomly in the spirit of statistical random sampling (not as
> before to generate different samples).
Stride sounds analogous. But if it can perform precisely this
mechanism you would need to use it twice and one of the applications
would need to be a stride over rows instead of a stride over pixels,
and I do not know if vcmprs supports that nor if there's another
mechanism for doing so. I'd have to spend more time than I feel
comfortable with, I think, to discover that.
Thanks,
--
Raul
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm