MCPcopy Create free account
hub / github.com/MotrixLab/AiOS / __init__

Method __init__

util/smplx/smplx/body_models.py:830–1000  ·  view source on GitHub ↗

SMPLX model constructor. Parameters ---------- model_path: str The path to the folder or to the file where the model parameters are stored num_expression_coeffs: int, optional Number of expression components to use (def

(self,
                 model_path: str,
                 num_expression_coeffs: int = 10,
                 create_expression: bool = True,
                 expression: Optional[Tensor] = None,
                 create_jaw_pose: bool = True,
                 jaw_pose: Optional[Tensor] = None,
                 create_leye_pose: bool = True,
                 leye_pose: Optional[Tensor] = None,
                 create_reye_pose=True,
                 reye_pose: Optional[Tensor] = None,
                 use_face_contour: bool = False,
                 batch_size: int = 1,
                 gender: str = 'neutral',
                 dtype=torch.float32,
                 ext: str = 'npz',
                 **kwargs)

Source from the content-addressed store, hash-verified

828 NECK_IDX = 12
829
830 def __init__(self,
831 model_path: str,
832 num_expression_coeffs: int = 10,
833 create_expression: bool = True,
834 expression: Optional[Tensor] = None,
835 create_jaw_pose: bool = True,
836 jaw_pose: Optional[Tensor] = None,
837 create_leye_pose: bool = True,
838 leye_pose: Optional[Tensor] = None,
839 create_reye_pose=True,
840 reye_pose: Optional[Tensor] = None,
841 use_face_contour: bool = False,
842 batch_size: int = 1,
843 gender: str = 'neutral',
844 dtype=torch.float32,
845 ext: str = 'npz',
846 **kwargs) -> None:
847 """SMPLX model constructor.
848
849 Parameters
850 ----------
851 model_path: str
852 The path to the folder or to the file where the model
853 parameters are stored
854 num_expression_coeffs: int, optional
855 Number of expression components to use
856 (default = 10).
857 create_expression: bool, optional
858 Flag for creating a member variable for the expression space
859 (default = True).
860 expression: torch.tensor, optional, Bx10
861 The default value for the expression member variable.
862 (default = None)
863 create_jaw_pose: bool, optional
864 Flag for creating a member variable for the jaw pose.
865 (default = False)
866 jaw_pose: torch.tensor, optional, Bx3
867 The default value for the jaw pose variable.
868 (default = None)
869 create_leye_pose: bool, optional
870 Flag for creating a member variable for the left eye pose.
871 (default = False)
872 leye_pose: torch.tensor, optional, Bx10
873 The default value for the left eye pose variable.
874 (default = None)
875 create_reye_pose: bool, optional
876 Flag for creating a member variable for the right eye pose.
877 (default = False)
878 reye_pose: torch.tensor, optional, Bx10
879 The default value for the right eye pose variable.
880 (default = None)
881 use_face_contour: bool, optional
882 Whether to compute the keypoints that form the facial contour
883 batch_size: int, optional
884 The batch size used for creating the member variables
885 gender: str, optional
886 Which gender to load
887 dtype: torch.dtype

Callers

nothing calls this directly

Calls 8

nameMethod · 0.95
StructClass · 0.85
find_joint_kin_chainFunction · 0.85
to_tensorFunction · 0.70
to_npFunction · 0.70
printFunction · 0.50
loadMethod · 0.45
__init__Method · 0.45

Tested by

no test coverage detected