wbia.algo package¶
Subpackages¶
- wbia.algo.detect package
- Subpackages
- Submodules
- wbia.algo.detect.azure module
- wbia.algo.detect.canonical module
- wbia.algo.detect.darknet module
- wbia.algo.detect.densenet module
- wbia.algo.detect.fasterrcnn module
- wbia.algo.detect.grabmodels module
- wbia.algo.detect.lightnet module
- wbia.algo.detect.orientation module
- wbia.algo.detect.randomforest module
- wbia.algo.detect.rf module
- wbia.algo.detect.selectivesearch module
- wbia.algo.detect.ssd module
- wbia.algo.detect.svm module
- wbia.algo.detect.yolo module
- Module contents
- wbia.algo.graph package
- Subpackages
- Submodules
- wbia.algo.graph.__main__ module
- wbia.algo.graph.core module
- wbia.algo.graph.demo module
- wbia.algo.graph.mixin_dynamic module
- wbia.algo.graph.mixin_groundtruth module
- wbia.algo.graph.mixin_helpers module
- wbia.algo.graph.mixin_loops module
- wbia.algo.graph.mixin_matching module
- wbia.algo.graph.mixin_priority module
- wbia.algo.graph.mixin_simulation module
- wbia.algo.graph.mixin_viz module
- wbia.algo.graph.mixin_wbia module
- wbia.algo.graph.nx_dynamic_graph module
- wbia.algo.graph.nx_edge_augmentation module
- wbia.algo.graph.nx_edge_kcomponents module
- wbia.algo.graph.nx_utils module
- wbia.algo.graph.refresh module
- wbia.algo.graph.state module
- Module contents
- wbia.algo.hots package
- Submodules
- wbia.algo.hots._pipeline_helpers module
- wbia.algo.hots.chip_match module
- wbia.algo.hots.exceptions module
- wbia.algo.hots.hstypes module
- wbia.algo.hots.match_chips4 module
- wbia.algo.hots.name_scoring module
- wbia.algo.hots.neighbor_index module
- wbia.algo.hots.neighbor_index_cache module
- wbia.algo.hots.nn_weights module
- wbia.algo.hots.old_chip_match module
- wbia.algo.hots.pipeline module
- wbia.algo.hots.query_params module
- wbia.algo.hots.query_request module
- wbia.algo.hots.requery_knn module
- wbia.algo.hots.scoring module
- wbia.algo.hots.toy_nan_rf module
- Module contents
- wbia.algo.preproc package
- wbia.algo.smk package
- wbia.algo.verif package
- Subpackages
- wbia.algo.verif.torch package
- Submodules
- wbia.algo.verif.torch.fit_harness module
- wbia.algo.verif.torch.gpu_util module
- wbia.algo.verif.torch.lr_schedule module
- wbia.algo.verif.torch.models module
- wbia.algo.verif.torch.netmath module
- wbia.algo.verif.torch.old_harness module
- wbia.algo.verif.torch.siamese module
- wbia.algo.verif.torch.train_main module
- Module contents
- wbia.algo.verif.torch package
- Submodules
- wbia.algo.verif.clf_helpers module
- wbia.algo.verif.deploy module
- wbia.algo.verif.oldvsone module
- wbia.algo.verif.pairfeat module
- wbia.algo.verif.ranker module
- wbia.algo.verif.sklearn_utils module
- wbia.algo.verif.verifier module
- wbia.algo.verif.vsone module
- Module contents
- Subpackages
Submodules¶
wbia.algo.Config module¶
DEPRICATE FOR CORE ANNOT AND CORE IMAGE DEFS
-
class
wbia.algo.Config.
AggregateConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
Old Agg Cfg
-
get_cfgstr
(**kwargs)¶
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
meta_get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
parse_items
(**kwargs)¶
-
-
class
wbia.algo.Config.
ChipConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
-
get_cfgstr
(**kwargs)¶
-
get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
parse_items
(**kwargs)¶
-
-
class
wbia.algo.Config.
DetectionConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
- CommandLine:
- python -m wbia.algo.Config –test-DetectionConfig
Example
>>> # ENABLE_DOCTEST >>> from wbia.algo.Config import * # NOQA >>> detect_cfg = DetectionConfig() >>> result = (detect_cfg.get_cfgstr()) >>> print(result) _DETECT(cnn,____,sz=800)
-
get_cfgstr
(**kwargs)¶
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
meta_get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
parse_items
(**kwargs)¶
-
class
wbia.algo.Config.
DisplayConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
-
get_cfgstr
(**kwargs)¶
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
meta_get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
parse_items
(**kwargs)¶
-
-
class
wbia.algo.Config.
FeatureConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
Feature configuration object.
TODO depcirate for core_annots.FeatConfig
- CommandLine:
- python -m wbia.algo.Config –test-FeatureConfig
Example
>>> # ENABLE_DOCTEST >>> from wbia.algo import Config # NOQA >>> from wbia.algo.Config import * # NOQA >>> feat_cfg = Config.FeatureConfig() >>> result = (feat_cfg.get_cfgstr()) >>> print(result) >>> #assert result.startswith('_FEAT(hesaff+sift_)_CHIP') _Feat(hesaff+sift)
-
get_cfgstr
(**kwargs)¶
-
get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
meta_get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
parse_items
(**kwargs)¶
-
class
wbia.algo.Config.
FeatureWeightConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
- CommandLine:
- python -m wbia.algo.Config –exec-FeatureWeightConfig
Example
>>> # ENABLE_DOCTEST >>> from wbia.algo.Config import * # NOQA >>> featweight_cfg = FeatureWeightConfig(fw_detector='rf', >>> featweight_enabled=True) >>> result = featweight_cfg.get_cfgstr() >>> print(result)
_FEATWEIGHT(ON,uselabel,rf)_FEAT(hesaff+sift_)_CHIP(sz450)
_FEATWEIGHT(OFF)_FEAT(hesaff+sift_)_CHIP(sz450)
-
get_cfgstr
(**kwargs)¶
-
get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
parse_items
(**kwargs)¶
-
class
wbia.algo.Config.
FlannConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
this flann is only for neareset neighbors in vsone/many TODO: this might not need to be here, should be part of neighbor config
References
http://www.cs.ubc.ca/research/flann/uploads/FLANN/flann_pami2014.pdf http://www.cs.ubc.ca/research/flann/uploads/FLANN/flann_manual-1.8.4.pdf http://docs.opencv.org/trunk/modules/flann/doc/flann_fast_approximate_nearest_neighbor_search.html
-
get_cfgstr
(**kwargs)¶
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
meta_get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
parse_items
(**kwargs)¶
-
-
class
wbia.algo.Config.
GenericConfig
(*args, **kwargs)[source]¶ Bases:
utool.Preferences.Pref
-
get_cfgstr
(**kwargs)¶
-
get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
parse_items
(**kwargs)¶
-
-
class
wbia.algo.Config.
NNConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
- CommandLine:
- python -m wbia.algo.Config –exec-NNConfig
Example
>>> # DISABLE_DOCTEST >>> from wbia.algo.Config import * # NOQA >>> nn_cfg = NNConfig() >>> nn_cfg = NNConfig(requery=True) >>> result = nn_cfg.get_cfgstr() >>> print(result) _NN(single,K=4,Kn=1,padk=False,cks800)
-
get_cfgstr
(**kwargs)¶
-
get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
parse_items
(**kwargs)¶
-
class
wbia.algo.Config.
NNWeightConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
- CommandLine:
- python -m wbia.algo.Config –test-NNWeightConfig
Example
>>> # ENABLE_DOCTEST >>> from wbia.algo.Config import * # NOQA >>> cfg_list = [ ... NNWeightConfig(), ... NNWeightConfig(can_match_sameimg=True, can_match_samename=False), ... NNWeightConfig(ratio_thresh=.625, lnbnn_on=False), ... NNWeightConfig(ratio_thresh=.625, lnbnn_normer='foobarstr'), ... ] >>> result = '\n'.join([cfg.get_cfgstr() for cfg in cfg_list]) >>> print(result) _NNWeight(lnbnn,fg,last,nosqrd_dist) _NNWeight(lnbnn,fg,last,sameimg,nosamename,nosqrd_dist) _NNWeight(ratio_thresh=0.625,fg,last,nosqrd_dist) _NNWeight(ratio_thresh=0.625,lnbnn,fg,last,lnbnn_normer=foobarstr,lnbnn_norm_thresh=0.5,nosqrd_dist)
-
get_cfgstr
(**kwargs)¶
-
get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
parse_items
(**kwargs)¶
-
class
wbia.algo.Config.
OccurrenceConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
- CommandLine:
- python -m wbia.algo.Config –exec-OccurrenceConfig –show
Example
>>> # DISABLE_DOCTEST >>> from wbia.algo.Config import * # NOQA >>> occur_cfg = OccurrenceConfig() >>> print(occur_cfg.get_cfgstr())
-
get_cfgstr
(**kwargs)¶
-
get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
parse_items
(**kwargs)¶
-
class
wbia.algo.Config.
OtherConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
-
get_cfgstr
(**kwargs)¶
-
get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
parse_items
(**kwargs)¶
-
-
class
wbia.algo.Config.
QueryConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
LNBNN ranking query configuration parameters
Example
>>> # ENABLE_DOCTEST >>> import wbia >>> ibs = wbia.opendb('testdb1') >>> cfg = ibs.cfg.query_cfg >>> cfgstr = ibs.cfg.query_cfg.get_cfgstr() >>> print(cfgstr)
-
apply_codename
(codename=None)[source]¶ codenames denote mass changes to configurations it is a hacky solution to setting different parameter values all at once.
-
get_cfgstr
(**kwargs)¶
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
meta_get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
parse_items
(**kwargs)¶
-
-
class
wbia.algo.Config.
SpatialVerifyConfig
(**kwargs)[source]¶ Bases:
utool.Preferences.Pref
Spatial verification
-
get_cfgstr
(**kwargs)¶
-
get_config_name
(**kwargs)¶ the user might want to overwrite this function
-
initialize_params
()¶ Initializes config class attributes based on params info list
-
keys
(**kwargs)¶
-
lookup_paraminfo
(key)¶
-
meta_get_cfgstr_list
(ignore_keys=None, **kwargs)¶ default get_cfgstr_list, can be overrided by a config object
-
parse_items
(**kwargs)¶
-
-
wbia.algo.Config.
load_named_config
(cfgname, dpath, use_config_cache=False, verbose=False)[source]¶ hack 12-30-2014
Parameters: Returns: cfg
Return type: - CommandLine:
- python -m wbia.algo.Config –test-load_named_config
Example
>>> # DISABLE_DOCTEST >>> from wbia.algo.Config import * # NOQA >>> from wbia.algo.Config import _default_config # NOQA >>> import wbia >>> ibs = wbia.opendb('PZ_Master0') >>> #ibs.cfg.save() >>> # build test data >>> cfgname = 'zebra_plains' >>> dpath = ibs.get_dbdir() >>> use_config_cache = True >>> # execute function >>> cfg = load_named_config(cfgname, dpath, use_config_cache) >>> # >>> keys1 = ut.take_column(cfg.parse_items(), 0) >>> keys2 = ut.take_column(ibs.cfg.parse_items(), 0) >>> symdiff = set(keys1) ^ set(keys2) >>> # verify results >>> result = str(cfg) >>> print(result)
-
wbia.algo.Config.
make_config_metaclass
()[source]¶ Creates a metaclass for Config objects that automates some of the more tedious functions to write
- Like:
- get_cfgstr and the comparison methods
Example
from wbia.algo.Config import * # NOQA @six.add_metaclass(ConfigMetaclass) class FooConfig(ConfigBase):
- def __init__(cfg):
- super(FooConfig, cfg).__init__(name=’FooConfig’) cfg.initialize_params()
- def get_param_info_list(cfg):
- return [
- ut.ParamInfo(‘x’, ‘y’), ut.ParamInfo(‘z’, 3),
]
cfg = FooConfig() logger.info(cfg.get_cfgstr(ignore_keys=[‘x’])) logger.info(cfg.get_cfgstr(ignore_keys=[]))
cfg = GenericConfig() cfg.x = ‘y’
-
wbia.algo.Config.
parse_config_items
(cfg)[source]¶ Recursively extracts key, val pairs from Config objects into a flat list. (there must not be name conflicts)
Example
>>> # ENABLE_DOCTEST >>> from wbia.algo.Config import * # NOQA >>> import wbia >>> ibs = wbia.opendb('testdb1') >>> cfg = ibs.cfg.query_cfg >>> param_list = parse_config_items(cfg)
Module contents¶
-
wbia.algo.
IMPORT_TUPLES
= [('Config', None, False), ('detect', None, True), ('hots', None, True), ('smk', None, True), ('preproc', None, True)]¶ cd /home/joncrall/code/wbia/wbia/algo makeinit.py –modname=wbia.algo
Type: Regen Command
-
wbia.algo.
reassign_submodule_attributes
(verbose=True)[source]¶ why reloading all the modules doesnt do this I don’t know
-
wbia.algo.
rrrr
(verbose=True)¶ Reloads wbia.algo and submodules