Module: tf.compat.v1.flags

Import router for absl.flags. See https://github.com/abseil/abseil-py

Modules

tf_decorator module: Base TFDecorator class and utility functions for working with decorators.

Classes

class ArgumentParser: Base class used to parse and convert arguments.

class ArgumentSerializer: Base class for generating string representations of a flag value.

class BaseListParser: Base class for a parser of lists of strings.

class BooleanFlag: Basic boolean flag.

class BooleanParser: Parser of boolean values.

class CantOpenFlagFileError: Raised when flagfile fails to open.

class CsvListSerializer: Base class for generating string representations of a flag value.

class DuplicateFlagError: Raised if there is a flag naming conflict.

class EnumClassFlag: Basic enum flag; its value is an enum class's member.

class EnumClassListSerializer: A serializer for MultiEnumClass flags.

class EnumClassParser: Parser of an Enum class member.

class EnumClassSerializer: Class for generating string representations of an enum class flag value.

class EnumFlag: Basic enum flag; its value can be any string from list of enum_values.

class EnumParser: Parser of a string enum value (a string value from a given set).

class Error: The base class for all flags errors.

class Flag: Information about a command-line flag.

class FlagHolder: Holds a defined flag.

class FlagNameConflictsWithMethodError: Raised when a flag name conflicts with FlagValues methods.

class FlagValues: Registry of 'Flag' objects.

class FloatParser: Parser of floating point values.

class IllegalFlagValueError: Raised when the flag command line argument is illegal.

class IntegerParser: Parser of an integer value.

class ListParser: Parser for a comma-separated list of strings.

class ListSerializer: Base class for generating string representations of a flag value.

class MultiEnumClassFlag: A multi_enum_class flag.

class MultiFlag: A flag that can appear multiple time on the command-line.

class UnparsedFlagAccessError: Raised when accessing the flag value from unparsed FlagValues.

class UnrecognizedFlagError: Raised when a flag is unrecognized.

class ValidationError: Raised when flag validator constraint is not satisfied.

class WhitespaceSeparatedListParser: Parser for a whitespace-separated list of strings.

Functions

DEFINE(...): Registers a generic Flag object.

DEFINE_alias(...): Defines an alias flag for an existing one.

DEFINE_bool(...): Registers a boolean flag.

DEFINE_boolean(...): Registers a boolean flag.

DEFINE_enum(...): Registers a flag whose value can be any string from enum_values.

DEFINE_enum_class(...): Registers a flag whose value can be the name of enum members.

DEFINE_flag(...): Registers a 'Flag' object with a 'FlagValues' object.

DEFINE_float(...): Registers a flag whose value must be a float.

DEFINE_integer(...): Registers a flag whose value must be an integer.

DEFINE_list(...): Registers a flag whose value is a comma-separated list of strings.

DEFINE_multi(...): Registers a generic MultiFlag that parses its args with a given parser.

DEFINE_multi_enum(...): Registers a flag whose value can be a list strings from enum_values.

DEFINE_multi_enum_class(...): Registers a flag whose value can be a list of enum members.

DEFINE_multi_float(...): Registers a flag whose value can be a list of arbitrary floats.

DEFINE_multi_integer(...): Registers a flag whose value can be a list of arbitrary integers.

DEFINE_multi_string(...): Registers a flag whose value can be a list of any strings.

DEFINE_spaceseplist(...): Registers a flag whose va