Граф коммитов

309 Коммитов

Автор SHA1 Сообщение Дата
Sasa Galic 90fcdc0b5a Merge master@{2016-03-07} into windows 2016-03-07 02:52:57 -08:00
Evan Shelhamer 880e147427 [pycaffe] test coord_map
- test known mappings: conv-pool-deconv stack, ReLU and 1x1 conv
- test effects of padding
- test rectangular/anisotropic coordinate mapping, test N-D
- catch error cases: negative crop, scale mismatch, tops that are not
  spatially connected
2016-03-04 19:09:51 -08:00
Evan Shelhamer 25b9ef95f3 [pycaffe] align coord_map and #3570 Crop layer
- crop -> offset
- adjust crop axis by 1
2016-03-04 19:09:51 -08:00
Evan Shelhamer 6149e7383e [pycaffe] document, style, and complete coord_map
- document by docstring and comment
- pep8
- add latest layers and alphabetize
- respect default crop params
- handle graphs with compositions of crops by walking only the
  first, cropped bottom of Crop layers
- make python3 happy by replacing arg tuple unpacking
2016-03-04 19:09:21 -08:00
Jonathan L Long 7a8b19f957 [pycaffe] add coord_map.py for computing induced coordinate transform
This provides a framework for automatically aligning different layers of
a net despite up/downsampling, padding, and output size rounding.
2016-03-04 15:30:51 -08:00
Evan Shelhamer c2354b9860 Merge pull request #3575 from errord/fix-boost-shared_ptr-caffe-Blob-float-no-register
[pycaffe] fix boost 1.60 compatibility issue; close #3494
2016-03-03 16:42:00 -08:00
Jon Long 559758d0c5 Merge pull request #3716 from ttdt/master
Use six library to ensure pycaffe.py python3 compliance
2016-03-02 16:23:14 -08:00
Anatoly Baksheev cb277769a4 NetSpec: allow setting blob names by string 2016-02-29 18:01:11 +03:00
Thibault Deregnaucourt 666da79ad2 Use 'six' library to ensure python3 compliance.
Use '//' instead of '/' for entire division.
2016-02-29 10:21:07 +01:00
shai 29bb23fc92 removing all references to Blob.num property (that assumes Blob is 4D). Replacing it with accessing Blob.shape[0] - for Blobs with num_axes() != 4 2016-02-23 10:42:54 +02:00
Pavle Josipovic 52f7402e14 Add support for windows build
Necessary changes to enable widndows build:
Visual studio project files.
Minor code chnages.
3rd party dependencies are resolved through NuGet.
2016-02-11 18:03:10 +01:00
Jeff Donahue a14ae47b53 Merge pull request #2144 from tishibas/load_image-improved
improved to load RGB image as grayscale image
2016-01-26 15:17:00 -08:00
Jeff Donahue 714b759268 Merge pull request #3581 from Austriker/draw-python3
Updated draw.py to make it work under Python 3
2016-01-26 09:38:20 -08:00
Hugo Serrat 407050e027 Updated import to make it work with pydotplus 2016-01-25 11:25:37 +01:00
Luke Yeager 67b497d4ec Version 1.0.0-rc3 2016-01-22 16:55:27 -08:00
biluochun 8fea1f5809 add register Net and Solver 2016-01-21 13:16:47 +08:00
biluochun de31e034e5 fixbug #issues/3494 No to_python (by-value) converter found for C++ type: boost::shared_ptr<caffe::Blob<float> > 2016-01-20 17:53:24 +08:00
philkr 1137e89fef Exposing layer top and bottom names to python 2016-01-04 21:17:09 -08:00
Evan Shelhamer 300f43f3ae dismantle layer headers
No more monolithic includes: split layers into their own headers for modular inclusion and build.
2015-12-01 21:13:43 -08:00
Luke Yeager c4190a56ab Skip python layer tests if WITH_PYTHON_LAYER unset 2015-11-18 10:38:32 -08:00
Alex Lee a29c2f7a0f Fix outs and diffs being overwritten in forward_backward_all. 2015-11-14 12:49:05 -08:00
ernest-tg 32dc03f14c Correct transposition & channel_swap in deprocess
The deprocess( ) function should invert the preprocess( ) function, however it only worked when the permutation of your channel_swap is of order 2 and the permutation of your transpose were of order 3. This is usually the case, which is why this bug went unnoticed for a long time.

To reproduce it (on former version), try to preprocess and then deprocess with
transformer.set_transpose('data', (0,2,1)) (or (1,0,2) or (2,1,0))

Or with
transformer.set_channel_swap('data', (2,0,1)) (or (1,2,0) )

Indeed, we had

L152  (in preprocess)   caffe_in = caffe_in[channel_swap, :, :]
L181  (in deprocess)    decaf_in = decaf_in[channel_swap, :, :]
So we applied [channel_swap,:,:] twice to the initial data => not always the identity

L154 (in preprocess)    caffe_in = caffe_in.transpose(transpose)
L183 (in deprocess)     decaf_in = decaf_in.transpose([transpose[t] for t in transpose])
The transposition [transpose[t] for t in transpose] is (tranpsose)² so we applied transpose[t] three times which is not always the identity.
2015-11-05 15:47:28 +01:00
René Scheibe 54f0c08ca1 fix detect.py (invalid model path) 2015-11-03 19:27:07 +01:00
Evan Shelhamer f5fd18b6cd Merge pull request #3082 from gustavla/pycaffe-snapshot
Expose `Solver::Snapshot` to pycaffe
2015-10-30 23:08:12 -07:00
Rodrigo Benenson 09b8738d73 diff.ndim != 4 is outdated
this code seems not to apply to the caffe head.
```
if diff.ndim != 4:
                raise Exception('{} diff is not 4-d'.format(top))
```
2015-10-22 18:18:08 +02:00
Ronghang Hu c1f7fe1cff Add automatic upgrade for solver type 2015-10-16 22:32:33 -07:00
Ronghang Hu b822a702d1 Split solver code into one file per solver class 2015-10-16 22:32:12 -07:00
Evan Shelhamer 3363e25287 Merge pull request #3190 from DrSleep/master
Fix drawing problems with repeated convolution -- close #3201
2015-10-16 17:59:13 -07:00
Luke Yeager 75e859a522 Allow old-style shape in blobproto_to_array
Fixes #3199
Bug introduced in #3170
2015-10-15 13:57:38 -07:00
Vladimir e0c34cedde Fixed drawing problems with repeated convolution 2015-10-14 12:00:14 +09:00
sh1r0 c65ba61bdf Remove the 4D constraint of blobproto IO in python 2015-10-09 00:37:52 +08:00
Gustav Larsson 19d9927d76 Add pycaffe test for solver.snapshot() 2015-10-05 22:41:01 -05:00
Yang Song 96ba513f54 Fix a typo
Fix a typo in the message.
2015-09-29 20:07:52 +08:00
Gustav Larsson b4f9add57f Expose `Snapshot` to pycaffe
- Solver::Snapshot is made public
- It is also added as `snapshot` to pycaffe

Addressing #3077
2015-09-17 20:33:44 -05:00
Tea f3a933a620 Separate IO dependencies
OpenCV, LMDB, LevelDB and Snappy are made optional via switches
(USE_OPENCV, USE_LMDB, USE_LEVELDB) available for Make and CMake
builds. Since Snappy is a LevelDB dependency, its use is determined by
USE_LEVELDB. HDF5 is left bundled because it is used for serializing
weights and solverstates.
2015-09-17 15:08:29 +08:00
Mohamed Omran b7f9cba875 removed bug in caffe.io.resize_image when applied to Nd images 2015-09-15 17:18:32 +02:00
Evan Shelhamer 5367a1af5d Merge pull request #3024 from danielgordon10/python-solver-fix
[pycaffe] expose all solvers for direct instantiation (although note get_solver)
2015-09-04 14:36:31 -03:00
Daniel Gordon 5cc76ad2e3 enabling the alternate solvers to be accessed by the python interface 2015-09-04 10:12:00 -07:00
Jeff Donahue c2484747d8 NetSpec: don't require lists to specify single-element repeated fields 2015-09-03 16:31:28 -07:00
Darren Garvey b04000e420 Cleanup: Fixup capitalisation of Caffe_POSTFIX.
Replaces CAffe_POSTFIX -> Caffe_POSTFIX.
2015-09-01 22:43:30 +01:00
Jon Long f572eefc8a Merge pull request #2944 from philkr/python_layer_param
Give the python layer parameter/weight blobs.
2015-08-26 18:12:17 -07:00
Jonas Maaskola c548a7972b Draw Deconvolution layers like Convolution layers 2015-08-26 15:06:58 +02:00
philkr 60c0d58baa Python parameter test added 2015-08-25 13:22:33 -07:00
philkr 6aecb43131 Allow the python layer have weight/parameter blobs. 2015-08-25 13:22:33 -07:00
Jeff Donahue aa2a6f55b9 Merge pull request #2930 from lukeyeager/pycaffe-layer_type_list
Expose LayerFactory::LayerTypeList in pycaffe
2015-08-20 11:04:05 -07:00
Luke Yeager 51b172ce2f Expose LayerFactory::LayerTypeList in pycaffe
Useful for validating NetParameters without crashing on SIGABRT
2015-08-20 10:06:22 -07:00
philkr e94be07e2d Exposing blob loss weight to python 2015-08-14 12:12:12 -07:00
Russell Stewart dde32b4ee6 Update net_spec.py 2015-08-10 13:50:01 -07:00
Evan Shelhamer eb3e1149a2 Merge pull request #2813 from longjon/net-spec-imp
Python net spec cleanups and top-less layers
2015-08-07 21:06:29 -07:00
Jon Long 633ad15dbc Merge pull request #2877 from jeffdonahue/pycaffe-shape-accessor
[pycaffe] add Blob shape accessor
2015-08-07 16:28:23 -07:00