From a1597cfc465ac02c195595d57316cc3bf5cecb6f Mon Sep 17 00:00:00 2001 From: Megvii Engine Team Date: Mon, 30 Mar 2020 18:08:06 +0800 Subject: [PATCH] docs(mge/param_pack): add description of param pack and add param pack in example run_dist GitOrigin-RevId: 1c900e159d043371a61479cb414b14bf31f48943 --- python_module/megengine/module/parampack.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/python_module/megengine/module/parampack.py b/python_module/megengine/module/parampack.py index fad1e27d..0f366115 100644 --- a/python_module/megengine/module/parampack.py +++ b/python_module/megengine/module/parampack.py @@ -16,6 +16,14 @@ from .._internal.opr import param_pack_split class ParamPack(Module): + r"""Pack module's parameters + + :param model: the module you want to pack parameters. + :param nr_ignore_first: how many parameters will be unpacked at first. + :param max_size_per_group: upper bound of packed parameters' size in MB. + :param max_nr_params_per_group: upper bound of the number of parameters of each group. + + """ def __init__(self, model: Module, nr_ignore_first:int = 8,