Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Small improvements to pycaffe #733

Merged
merged 3 commits into from
Jul 28, 2014
Merged

Small improvements to pycaffe #733

merged 3 commits into from
Jul 28, 2014

Conversation

longjon
Copy link
Contributor

@longjon longjon commented Jul 19, 2014

I haven't tested these exact commits yet, although I've made the same changes elsewhere in the past.

These three commits:

Expanding on the last point in particular:

  • Right now setting input_scale to zero is the same as setting input_scale to one, due to the check if input_scale. Allowing the multiplication/division by zero properly breaks things or produces warnings.
  • Right now setting channel_order to () or 0 is the same as setting it to the identity, due to the check if channel_order. Note that both of these are valid indices in numpy, although actually using them in this context is probably a mistake. Allowing the indexing will make such usages crash in most cases, instead of continuing as if the input were valid.

It doesn't make sense to complain about input not being batch-sized if
it isn't even 4-d in the first place.
An input_scale of zero should produce warnings/errors/infinities rather
than being the same as an input_scale of one. A channel_order of () or 0
should not be equivalent to the default ordering.
@shelhamer
Copy link
Member

Thanks for the Python fixes Jon! I'll combine with improvements from #735 and release to master.

shelhamer added a commit that referenced this pull request Jul 28, 2014
@shelhamer shelhamer merged commit d842f4a into BVLC:dev Jul 28, 2014
@shelhamer shelhamer mentioned this pull request Aug 8, 2014
mitmul pushed a commit to mitmul/caffe that referenced this pull request Sep 30, 2014
RazvanRanca pushed a commit to RazvanRanca/caffe that referenced this pull request Nov 4, 2014
@longjon longjon deleted the pycaffe-tweaks branch December 30, 2014 05:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants