pytorch/caffe2/python
Aapo Kyrola 46a95cf420 Allow specifying device to load_from_db()
Summary: A quite common problem is that it is hard to load blobs with pe.load_from_db to a specific device. One must set the device options of the returned init_net and predict_init_net, which is quite magical. So I made load_from_db() able to set these device options automatically, based on device scope or device_option parameter. Added an unit test.

Reviewed By: asaadaldien

Differential Revision: D5249202

fbshipit-source-id: 7b9d91476cb8d1b0ec0d9772e50b9148b8b184fa
2017-06-14 14:32:24 -07:00
..
docs fixed operators schema output to work from only this file for OSS 2017-06-02 13:47:25 -07:00
examples resnet50: fetch right lr 2017-06-07 21:46:35 -07:00
helpers add_helper_function_ElementwiseLinear_op 2017-06-07 13:49:48 -07:00
layers add truncation for sparse feature 2017-06-13 10:46:53 -07:00
mint
mkl
modeling Create ParameterSharing abstraction for Caffe2. 2017-06-05 11:49:54 -07:00
models Probably fixed memonger 2017-06-08 09:19:24 -07:00
operator_test MaxReduction ops GPU implementation. 2017-06-14 11:02:46 -07:00
predictor Allow specifying device to load_from_db() 2017-06-14 14:32:24 -07:00
rnn CuDNN comparison mode 2017-05-20 15:19:43 -07:00
_import_c_extension.py
attention.py Fixes range/xrange for Python 3 2017-06-07 00:04:26 -07:00
brew.py add_helper_function_ElementwiseLinear_op 2017-06-07 13:49:48 -07:00
brew_test.py Fixing broken Python tests 2017-06-08 13:34:46 -07:00
caffe_translator.py Fixed typo caffe_translator.py, fixes bug #397 2017-05-24 12:18:32 -07:00
caffe_translator_test.py
checkpoint.py
checkpoint_test.py Fixes the checkpoint test. 2017-06-12 12:19:14 -07:00
CMakeLists.txt
cnn.py cnnmodelhelper deprecate warning 2017-05-18 23:35:26 -07:00
context.py
context_test.py
control.py
control_test.py
convnet_benchmarks.py
convnet_benchmarks_test.py
core.py Remove WORKER_INIT_CALLS 2017-06-13 20:18:48 -07:00
core_gradients_test.py Operator python traceback 2017-06-13 18:50:02 -07:00
core_test.py Operator python traceback 2017-06-13 18:50:02 -07:00
crf.py Deprecate CNNModelHelper in python/crf.py 2017-06-14 08:49:27 -07:00
data_parallel_model.py Fixes range/xrange for Python 3 2017-06-07 00:04:26 -07:00
data_parallel_model_test.py Fixes range/xrange for Python 3 2017-06-07 00:04:26 -07:00
data_workers.py Fixes range/xrange for Python 3 2017-06-07 00:04:26 -07:00
data_workers_test.py add test for input order 2017-05-19 23:46:38 -07:00
dataio.py checkpointing for distributed hive reader. 2017-06-06 14:20:06 -07:00
dataio_test.py Explicitly set should_stop_blob to False in pipeline init 2017-06-11 02:33:42 -07:00
dataset.py
db_test.py String-related fixes for Python 3 2017-05-26 16:04:32 -07:00
device_checker.py
dyndep.py
empty.so Adding video data layer for caffe2 2017-05-05 14:16:38 -07:00
experiment_util.py
extension_loader.py
gradient_check_test.py Network forward / backward equality checker 2017-06-08 17:48:47 -07:00
gradient_checker.py Network forward / backward equality checker 2017-06-08 17:48:47 -07:00
hsm_util.py
hypothesis_test.py Add gradient to SparseToDense op 2017-06-09 13:47:21 -07:00
hypothesis_test_util.py Fixes range/xrange for Python 3 2017-06-07 00:04:26 -07:00
layer_model_helper.py fix for realtime training. 2017-05-26 23:49:40 -07:00
layer_model_instantiator.py Remove map() and filter() in favor of comprehensions 2017-05-30 15:32:58 -07:00
layer_test_util.py Add batch normalization layer 2017-05-26 16:46:52 -07:00
layers_test.py Fixes range/xrange for Python 3 2017-06-07 00:04:26 -07:00
load_save_test.py
lstm_benchmark.py lstm_benchmark use rnn_cell.LSTM multicell + assertion 2017-05-04 17:02:32 -07:00
memonger.py Probably fixed memonger 2017-06-08 09:19:24 -07:00
memonger_test.py Probably fixed memonger 2017-06-08 09:19:24 -07:00
mkl_test_util.py
model_device_test.py
model_helper.py Support fetching of the parameters from the global namescope by '' 2017-06-05 22:32:39 -07:00
mpi_python.cc Fix pybind11 module name for MPI helpers 2017-05-02 23:18:50 -07:00
muji.py Fixes range/xrange for Python 3 2017-06-07 00:04:26 -07:00
muji_test.py Fixes range/xrange for Python 3 2017-06-07 00:04:26 -07:00
net_builder.py Remove map() and filter() in favor of comprehensions 2017-05-30 15:32:58 -07:00
net_builder_test.py Remove map() and filter() in favor of comprehensions 2017-05-30 15:32:58 -07:00
net_drawer.py net_drawer: --input is required 2017-05-04 11:45:57 -07:00
net_printer.py net_printer_quick_fix 2017-06-08 19:34:50 -07:00
net_printer_test.py Remove map() and filter() in favor of comprehensions 2017-05-30 15:32:58 -07:00
optimizer.py Fix multi-precision SGD outputs 2017-06-14 11:36:43 -07:00
optimizer_test.py add_weight_decay + restore weight decay to resnet50_trainer 2017-06-02 14:16:56 -07:00
optimizer_test_util.py Fp16 training initializers 2017-06-01 08:34:46 -07:00
pipeline.py Explicitly set should_stop_blob to False in pipeline init 2017-06-11 02:33:42 -07:00
predictor_constants.py
pybind_state.cc Operator python traceback 2017-06-13 18:50:02 -07:00
pybind_state.h Run python op builder at op creation time 2017-06-13 16:29:22 -07:00
pybind_state_gpu.cc
pybind_state_mkl.cc
python_op_test.py Run python op builder at op creation time 2017-06-13 16:29:22 -07:00
queue_util.py
record_queue.py
recurrent.py Static RNN 2017-06-08 17:48:48 -07:00
rnn_cell.py Static RNN 2017-06-08 17:48:48 -07:00
schema.py Fix from_column_list 2017-06-06 01:17:02 -07:00
schema_test.py Fix from_column_list 2017-06-06 01:17:02 -07:00
scope.py quick fix future issue with brew/core/schema/workspace/scope/utils.py 2017-06-05 12:01:48 -07:00
scope_test.py
session.py
session_test.py
sparse_to_dense_mask_test.py String-related fixes for Python 3 2017-05-26 16:04:32 -07:00
task.py fix potential bug in task.py 2017-06-11 10:40:47 -07:00
test_util.py
text_file_reader.py
timeout_guard.py
toy_regression_test.py
tt_core.py
tt_core_test.py
utils.py Misc fixes for Python 3 2017-06-13 12:18:43 -07:00
visualize.py
workspace.py Operator python traceback 2017-06-13 18:50:02 -07:00
workspace_test.py String-related fixes for Python 3 2017-05-26 16:04:32 -07:00