mirror of
https://github.com/deepfakes/faceswap
synced 2025-06-08 20:13:52 -04:00
- Split up cli.py to smaller modules - Enable Multi Mask Selection in Extraction - Handle multi option selection options in the GUI - Document lib/cli
27 lines
1 KiB
Python
27 lines
1 KiB
Python
#!/usr/bin/env python3
|
|
""" Command Line Arguments for tools """
|
|
from lib.cli.args import FaceSwapArgs
|
|
from lib.cli.actions import DirFullPaths
|
|
|
|
_HELPTEXT = "This command lets you restore models from backup."
|
|
|
|
|
|
class RestoreArgs(FaceSwapArgs):
|
|
""" Class to restore model files from backup """
|
|
|
|
@staticmethod
|
|
def get_info():
|
|
""" Return command information """
|
|
return "A tool for restoring models from backup (.bk) files"
|
|
|
|
@staticmethod
|
|
def get_argument_list():
|
|
""" Put the arguments in a list so that they are accessible from both argparse and gui """
|
|
argument_list = list()
|
|
argument_list.append({"opts": ("-m", "--model-dir"),
|
|
"action": DirFullPaths,
|
|
"dest": "model_dir",
|
|
"required": True,
|
|
"help": "Model directory. A directory containing the model "
|
|
"you wish to restore from backup."})
|
|
return argument_list
|