Youwei Song
d5ff79e55e
Support numpy bridge (enabled by default in dygraph mode) ( #20983 )
...
* add numpy bridge
* fix template compile
* add unittest, add default
test=develop
* fix unittest
test=develop
* fix unittest
test=develop
* zero_copy=True for to_variable,
test=develop
* bug fix
test=develop
* disable deprecated NumPy API
test=develop
* use better design of NumpyAllocator
test=develop
* fix Py_None check
test=develop
* reset c++ tracer when jump out dygraph guard
test=develop
* refine PADDLE_ENFORCE_xx format
test=develop
* bug fix of tracer switch
test=develop
* update decref
test=develop
6 years ago
Zeng Jinle
67e88424e5
Polish jit trace codes ( #21218 )
...
* polish jit trace codes, test=develop
* polish codes again by removing var_id, test=develop
6 years ago
Zeng Jinle
0f30d3a213
fix dygraph trace bug, test=develop ( #21193 )
6 years ago
Zeng Jinle
5fdfbe3413
Add friendly dygraph trace API ( #21091 )
...
* friendly trace interface, test=develop
* refine TracedLayer, test=develop
* add some docs, test=develop
6 years ago
Wojciech Uss
226bc22a29
Remove fuse_with_relu argument from batch_norm constructor ( #21028 )
...
test=develop
6 years ago
Leo Chen
008ed65fd5
Add c++ global current tracer for dygraph ( #20882 )
...
* Add c++ global current tracer for dygraph, test=develop
* add tracer property in c++, test=develop
* support different place, test=develop
* add unittest for tracer, test=develop
6 years ago
Leo Chen
9974e40787
Update Tensor.set() to support float16 ( #19964 )
...
* don't expose numerous Tensor.set(), test=develop
* fix condition, test=develop
* fix float16 bug, test=develop
* feed should be Tensor or np.array, not Variable or number, test=develop
* use forcecast to copy numpy slice to new array, test=develop
* remove float16-uint16 hacking, test=develop
6 years ago
Youwei Song
2058bab1c0
Add Sequential api ( #20789 )
...
* add Sequential api
test=develop
* fix unittest
test=develop
* refine code sample
* test=develop
6 years ago
Zeng Jinle
378fc4fb1c
add some docs to jit.trace, test=develop ( #20811 )
6 years ago
Zeng Jinle
8ff6b289bd
[Dygraph to static graph]JIT/Trace ( #20775 )
...
* jit/trace 1st version, test=develop
* add more unittests, test=develop
6 years ago
Youwei Song
9a09ff14a5
fix en docs of Layer and guard ( #20512 )
...
* fix en docs of Layer and guard
test=document_fix, test=develop
* fix en docs of Layer and guard
test=document_fix, test=develop
* minor fix
test=document_fix, test=develop
* minor fix
test=document_fix, test=develop
* fix api.spec
test=document_fix, test=develop
* fix api.spec
test=document_fix, test=develop
* fix docs
test=document_fix, test=develop
* fix docs
test=document_fix, test=develop
* fix docs
test=document_fix, test=develop
* fix api.spec
test=document_fix, test=develop
* fix api.spec
test=document_fix, test=develop
* add forward doc
test=document_fix, test=develop
* add "s" for parameters
test=document_fix, test=develop
6 years ago
LielinJiang
faa8e30a14
Set batch norm and data norm argument 'do_model_average_for_mean_and_var' default as True ( #20421 )
...
* fix_norm_model_average_bug
* test=develop
* refine comment test=develop
* refine comment test=develop
6 years ago
zhongpu
0b321c8a2f
fix APIs, to_variable、NCE、PRelu、softmax、rankloss for dygraph, test=document_fix, test=develop ( #20142 )
6 years ago
zhongpu
52dcc1679d
fix Embedding API for dygraph ( #20358 )
...
* fix Embedding API for dygraph, test=develop, test=document_fix
* fix dtype, test=develop, test=document_fix
6 years ago
DuYao
76a5819728
update English document ( #20330 )
...
* update English document, test=document_fix
* update api.spec, test=document_fix
* update api.spec, test=document_fix
* update, test=document_fix
6 years ago
zhongpu
95e5768bd6
update conv, fc, pool op for dygraph, test=develop ( #20132 )
6 years ago
zhongpu
9ca417f1d0
fix APIs, update norm op, test=develop ( #20119 )
...
* update norm op, test=develop, test=document_fix
* fix norm api, test=develop, test=document_fix
6 years ago
hong
fa43e80e19
New save load interface ( #20148 )
...
* add new save load interface; test=develop
* add new save interface; test=develop
* add save load interface ;
* fix save load error;
* fix dygraph set dict bug;
* add save load unit test; test=develop
* fix test_imperative_optimizer bug; test=develop
* fix unitest optimizer bug; test=develop
* fix code coverage; test=develop
* fix converage; test=develop
* add document for apis; test=develop
* fix unitest error; test=develop
* fix save load unit test error; test=develop
* fix error message; test=develop
* change set_parameter set_optimizer to save_dygraph; test=develop
* add load_graph check; test=develop
* fix api spec; test=develop
6 years ago
Youwei Song
54e07994ee
Dygraph Layer kwargs & param getter setter ( #19901 )
...
* opt FC
* opt rest of dygraph.nn
* new param shape check and unittest
* add kwargs for Layer
* add new set_value api
* use property decorator
* update API.spec, test=develop
* use UserList, separate gettersetters, test=develop
* update test_custom_layer_with_kwargs, test=develop
* fix UserList compatibility, test=develop
* fix UserList compatibility, test=develop
* keep FC._w, test=develop
* add unittests, Conv3D bug fix, test=develop
* clean code, test=develop
* fix dygraph guard in unittest, test=develop
* add property setters, remove unused param in tracer, test=develop
* tracer none check, test=develop
* merge, test=develop
* refine, test=develop
* bug fix in prelu and conv3d_transpose, test=develop
* rm __set__, test=develop
* set tensor value instead of assign op
* fix property setter call, test=develop
* fix api.spec, test=develop
* fix doc sample, test=develop
6 years ago
Jiabin Yang
39ff0f9cd9
Optimze/optimize dygraph api ( #19999 )
...
* test=develop, fix docker with paddle nccl problem
* test=develop, Add Variable api and refine dygraph related API
* test=develop, Add Variable api and refine dygraph related API
* test=develop, refine test for new api and error info
* test=develop, refine error info and test_layers
* test=develop, add API.spec
* test=devleop, fix to_string python2 and python3 compat error and refien doc
* test=devleop, add API spec
* test=devleop, update API spec
* test=devleop, update API spec
* test=develop, invoke ci
* test=develop, fix example code
* test=develop, update API spec
* test=develop, add compat test and fix inplace campat dict error
6 years ago
chengduo
b99fc38cec
Add fp16 support for dygraph ( #19828 )
...
* Add fp16 support for dygraph
test=develop
* Add unit test
test=develop
6 years ago
Youwei Song
3e5fb6361b
fix api-doc error for dygraph and backward ( #19721 )
...
* update dygraph api-doc and backward api-doc, test=develop
* update dygraph api-doc and backward api-doc, update api.spec, test=develop
* update dygraph api-doc and backward api-doc, update api.spec, test=develop
* update API.spec, test=develop
6 years ago
Chen Weihang
73daa3d6c0
Code Cleanup: delete three useless raw variables in Conv2D ( #19644 )
...
* delete useless raw variables in Conv2D, test=develop
* adjust the vars number in test_graph_wrapper to pass unittest, test=develop
6 years ago
Jiabin Yang
e9233d1c1e
Refactor dygraph ( #19107 )
...
* refactor dygraph,test=develop
* fix failed unittest,test=develop
* polish code,test=develop
* check windows ci error,test=develop
try to fix windows ci error by np.allclose,test=develop
* polish vlog and profiler, test=develop
* try to fix preceding ops order,test=develop
* test transformer in windows ci, test=develop
* use python c-api to speed up tracer.trace,test=develop
* test=develop, fix docker with paddle nccl problem
* test=develop, add ut for debug string and gradient_accumulator
* test=develop, add tests for layer/gradient_accumulator/prepared_op
* test=develop, fix complie error for test_prepared_op
* test=develop, add more ut for dygraph
* test=develop, create API.spec for dygraph api change
* test=develop, refoctor name to make it easier to understand
* test=develop, refoctor name to make it easier to understand
* test=develop, fix multi-gpu failed problem , add Tracer tests, change PADDLEENFORCE to PADDLEENFORCE_EQ
* test=develop, fix ut failed on parallel se-resnext
* test=develop, change one more PADDLE_ENFORCE
6 years ago
Youwei Song
9a577f2e41
fix batchnorm api param: data_layout ( #19524 )
...
* fix batchnorm api param: data_layout
* fix batchnorm data_layout param; test=develop
6 years ago
Jiabin Yang
1ce0a09e60
fix con2d transpose bias by create and init it in build_once ( #18968 )
...
* fix con2d transpose bias by create and init it in build_onee
* fix API spec
* test=develop, invoke ci
* fix bias_attr and act has no effect error on layer norm, conv2dTranpose, billinearTensorProduct, sequece_conv. fix original_mode not used error on GRUunit. fix sample_weight not set error on NCE. Add ut for all thoese layer
* test=develop, change success standard for conv2dTranspose
* test=develop, fix test_layers to invoke some error branch
* test=develop, fix sample code
* test=develop, fix BilinearTensorProduct failed in dygraph mode
* test=develop, fix test_layers segment fault error
6 years ago
Ghost Under Moon
10643b4ea6
fix- raise io error when user load from non-existed dir test=develop ( #19384 )
...
This PR fix problem with issue #18096 , which raise an error for user to specify the error about load dir is wrong
6 years ago
Jiabin Yang
55931db449
fix problem that get_attr method can't using default mode when we call has_attr in dygraph ( #19328 )
...
* add default getItem
* test=develop, fix has_attr disabled error in Layer
* test=develop, fix GroupNorm and deepcf bug on attrs
6 years ago
chengduo
5a579df9ba
[Speedup] Make dygraph data parallel faster ( #19280 )
...
* update parallel.py
test=develop
6 years ago
chengduo
20859c08e8
[DyGraph] Make multi-card program faster ( #18892 )
...
* update parallel.py
test=develop
6 years ago
lujun
b6d5c74f69
update dygraph api doc for web ( #18550 )
...
remove dygraph.enable from __all__
hidden dygraph. profiler
add doc to dygraph. no_grad
6 years ago
Jiabin Yang
7586cdd545
Hide no support ( #18515 )
...
* test=develop, fix docker with paddle nccl problem
* test=develop, hide no_support api and add ut for it
6 years ago
lujun
fd6631ef2f
Fix dygraph show style ( #18297 )
...
Fix dygraph show style for FluidDoc.
6 years ago
Zeng Jinle
25ab23be28
Fix dygraph mem leak ( #18082 )
...
* fix dygraph mem leak, test=develop
* polish msg, test=develop
6 years ago
lujun
dcaf60f06c
Fix dygraph doc at nn.py for v1.5 ( #17904 )
...
fix doc: conv3d, layer norm, bilineartensorproduct, conv2dtranspose, conv3dtranspose,rowconv, groupnorm, spectralnorm, treeconv
hidden api: sequenceConv
6 years ago
Hongyu Liu
2a9d74f67c
Add comment for dygraph api ( #17869 )
...
* add api commet; test=develop
* fix fc dtype bug; test=develop
* remove float32 in default parameter; test=develop
* fix exmpale bug; test=develop
* fix build once; test=develop
* fix num_chanels bug; test=develop
* fix install check failed bug; test=develop
6 years ago
Jiabin Yang
4d5f6937c3
Feature/refine api for dygraph ( #17907 )
...
* WIP
* WIP
* test=develop, add api doc and example code for dygraph
6 years ago
Jiabin Yang
fba10b6bb5
test=develop, refine api ( #17883 )
...
* test=develop, refine api
* test=develop, fix bug when error occured on save_persistable with no optimizer
* test=develop, refine waring
* test=develop, refine example code and comments
6 years ago
Jiabin Yang
4cb7d32c9b
test=develop, add dygraph_not_support and refine ocr ( #17868 )
...
* test=develop, add dygraph_not_support and refine ocr
* test=develop, shrink name of dygraph_not_support
6 years ago
xiaoting
545afb2d74
Add trainable_statist attr for bn in dygraph ( #17881 )
...
* add import, test=develop
* fix fill_constant
* fix deconv
* add trainable_statist for bn in dygraph
6 years ago
Jiabin Yang
3bfb92c32b
test=develop, hide build_once ( #17871 )
6 years ago
Jiabin Yang
022dfed4fc
Add optimizer save and load ( #16986 )
...
* save optimizer related vars in dygraph
* test=develop, add optimizer save and load
* test=develop, add optimizer save and load
* test=develop, merge code and add multi-optimizer save and load
* test=develop, fix test_imperative_checkpoint
* test=develop, fix include error
* test=develop, fix include error
* test=develop, renew api spec
* test=develop, refine code
* test=develop, set default value for checkpoint
* test=develop, fix ci error
* test=develop, change API.spec and make api more readable
* test=develop, refine version and time stamp
* test=develop, add example code and refine code
* test=develop, refine doc
* test=develop, change version
6 years ago
Zeng Jinle
674e0ce2d6
Use Python C-API to speed up dygraph trace ( #17837 )
...
* use python api to reduce python time cost, test=develop
* fix travis ci, test=develop
* fix Py_None error,test=develop
6 years ago
Jiabin Yang
3b70f870e2
Using Smart pointer to optimizer memory usage of dyGraph ( #17768 )
...
* for debug
* test=develop, memory optimize for dygraph using shared_ptr
* test=develop, fix travis ci showed error
* test=develop, fix bug for recurrent usage of varbase
* test=develop, init varbase when it need to be Add
6 years ago
Zeng Jinle
3a6ead24ad
Add no_grad decorator to dygraph ( #17790 )
...
* add no_grad decorator to dygraph, test=develop
* add unittest,test=develop
6 years ago
lujun
7f1c626921
Fix potential bugs: use numpy assignment to restore parameters at build-once, test=develop ( #17720 )
...
use numpy assignment to restore parameters at build-once
6 years ago
Hongyu Liu
aca53535e0
fix bug; test=develop ( #17733 )
6 years ago
Jiabin Yang
effc555955
test=develop, layz init Grad ( #17653 )
6 years ago
lujun
0f2e7a48c8
fix:Modify keys in the dictionary of layer.stat_dict in dynamic graph mode, test=develop ( #17700 )
6 years ago
chengduo
21d7b78602
update parallel_helper ( #17691 )
...
test=develop
6 years ago
Zeng Jinle
432ac70124
clean code of py_layer in dygraph mode,test=develop ( #17661 )
6 years ago
chengduo
b5f4d5ed0e
Add broadcast operators ( #17503 )
...
* This PR adds broadcast for multi-process. And it could be used in dynamic graph to broadcast parameters.
6 years ago
Jiabin Yang
ff5fdc0b67
test=develop, fix con2d with no bias ( #17516 )
...
* test=develop, fix con2d with no bias
* test=develop, fix conv_2d with no bias will have null shape
6 years ago
Jiabin Yang
d2682a84ca
test=develop, fix dygraph batch_norm ( #17465 )
6 years ago
Hongyu Liu
306eadcd39
fix eval mode bug; test=develop ( #17499 )
6 years ago
Yan Xu
0217555530
polish parallel dygraph code ( #17164 )
...
* add var grad hook test=develop
6 years ago
Zeng Jinle
eab34b2df6
fix_dygraph_mem_leak, test=develop ( #17396 )
6 years ago
Jiabin Yang
4624d7c642
test=develop, add gradient sort backward strategy ( #17125 )
...
* test=develop, add gradient sort backward strategy
* test=develop, fix test by add FLAGS_cudnn_deterministic on new tests
6 years ago
Jiabin Yang
d8af44a5a3
test=develop, fix error with training and test on diff device ( #17276 )
6 years ago
Zeng Jinle
5dfe2ab9e8
Fix mem leak when converting Tensor to numpy array ( #17182 )
...
* fix mem leak when converting Tensor to numpy array
test=develop
* remove unused unittest,test=develop
* follow comments, test=develop
* fix dygraph bug,test=develop
6 years ago
Yan Xu
0b07eef118
ParallelDyGraph with GPU collective mode ( #16827 )
...
implement dygraph.parallel.DataParallel to hook reduce op.
6 years ago
lujun
9d2f7d762c
fix dy-load bug, test=develop
6 years ago
lujun
94c4cd1a98
fix dy-load bug, test=develop
6 years ago
lujun
a3f17280a3
fix dy-load bug, test=develop
6 years ago
lujun
dbf66dd034
Merge pull request #16954 from junjun315/fix-dygraph-checkpoint
...
Fix dygraph checkpoint bug
6 years ago
lujun
a7c11979ba
fix dygraph save/load checkpoint error, test=develop
6 years ago
minqiyang
97aa1838bc
Fix dygraph train mode
...
test=develop
6 years ago
minqiyang
73cbdc2998
Add train mode
...
test=develop
6 years ago
minqiyang
734260f47b
Make Op Hold Output too and release backward_refs each time
...
test=develop
6 years ago
minqiyang
20e304f2ae
Tracer does not hold op any more
...
test=develop
6 years ago
lujun
92c8ac8a74
merge conflict, test=develop
6 years ago
minqiyang
2e0b871320
Merge branch 'develop' of https://github.com/PaddlePaddle/Paddle into imperative_dqn
6 years ago
Yan Xu
b4c3a6aa0b
[Imperative] implement imperative NCCLParallelContext ( #16477 )
...
add NCCLParallelContext for parallel dygraph
6 years ago
lujun
01f4f2d7e4
merge confict, test=develop
6 years ago
minqiyang
61fe139f34
Polish code
6 years ago
lujun
e11bf2a49e
merge branch, test=develop
6 years ago
lujun
a32c6ffa96
Merge branch 'develop' of https://github.com/PaddlePaddle/Paddle into move-api-to-root
6 years ago
minqiyang
e377d75977
Add UT for most layers without params
...
test=develop
6 years ago
lujun
ad7c1a934f
merge conficts, test=develop
6 years ago
lujun
60e3e35575
merge branch, test=develop
6 years ago
Jiabin Yang
353244f4fc
test=develop, add FC and test ( #16604 )
...
* test=develop, add FC and test
* test=develop, refine code
6 years ago
lujun
717256755a
move dygraph.nn,dygraph.layer to fluid, test=develop
6 years ago
lujun
cf6238fbd9
fix merge for move dir, fix utest error, test=develop
6 years ago
lujun
1dcd28e819
move dygraph.nn,dygraph.layer to fluid, test=develop
6 years ago
lujun
5470c29daa
fix merge for move dir, fix utest error, test=develop
6 years ago
minqiyang
fb7c787d34
Fix conflicts
...
test=develop
6 years ago
minqiyang
3e57981294
Merge branch 'develop' of https://github.com/PaddlePaddle/Paddle into imperative_lr_scheduler
...
test=develop
6 years ago
lujun
d4d5052fa6
fix merge for move dir, fix utest error, test=develop
6 years ago
lujun
32146857a4
Merge branch 'develop' of https://github.com/PaddlePaddle/Paddle into move-code
6 years ago
lujun
1c9aaeebe0
move imperative to dygraph, test=develop
6 years ago