birdnet.geo.models.v3_0 package¶
Submodules¶
birdnet.geo.models.v3_0.model module¶
- class birdnet.geo.models.v3_0.model.GeoDownloaderBaseV3_0¶
Bases:
object-
AVAILABLE_LANGUAGES:
OrderedSet[str] = OrderedSet(['en_us', 'de', 'es', 'pl', 'fr', 'nl', 'ru', 'ja', 'cs', 'ca', 'pt', 'no', 'bg', 'sv', 'da', 'tr', 'sk', 'sr', 'uk', 'zh', 'fi', 'es_es', 'es_mx', 'es_ec', 'pt_pt', 'hr', 'lt', 'fa', 'cy'])¶
- classmethod ensure_labels_available()¶
- Return type:
None
- classmethod get_lang_file(lang)¶
- Return type:
Path
-
AVAILABLE_LANGUAGES:
- class birdnet.geo.models.v3_0.model.GeoModelV3_0(model_path, species_list, is_custom_model, backend_type, backend_kwargs)¶
Bases:
GeoModelBase- final classmethod get_model_type()¶
- Return type:
Literal['acoustic','geo']
- final classmethod get_version()¶
- Return type:
Literal['2.4','3.0']
- classmethod load(model_path, species_list, backend_type, backend_kwargs)¶
- Return type:
- classmethod load_custom(model_path, species_list, backend_type, backend_kwargs, check_validity)¶
- Return type:
- predict(latitude, longitude, /, *, week=None, year_round_aggregation='max', min_confidence=0.03, half_precision=False, device='CPU')¶
- Return type:
- predict_session(*, min_confidence=0.03, half_precision=False, device='CPU')¶
- Return type:
birdnet.geo.models.v3_0.tf module¶
- class birdnet.geo.models.v3_0.tf.GeoTFBackendFP16V3_0(model_path, device_name, half_precision, **kwargs)¶
Bases:
TFBackend,VersionedGeoBackendProtocol- classmethod encoding_out_idx()¶
- Return type:
int|None
- classmethod in_idx()¶
- Return type:
int
- load()¶
- Return type:
None
- classmethod precision()¶
- Return type:
Literal['int8','fp16','fp32']
- classmethod prediction_out_idx()¶
- Return type:
int
- classmethod supports_encoding()¶
- Return type:
bool
- classmethod year_round_week_inputs()¶
- Return type:
tuple[float,...]
- class birdnet.geo.models.v3_0.tf.GeoTFBackendFP32V3_0(model_path, device_name, half_precision, **kwargs)¶
Bases:
TFBackend,VersionedGeoBackendProtocol- classmethod encoding_out_idx()¶
- Return type:
int|None
- classmethod in_idx()¶
- Return type:
int
- load()¶
- Return type:
None
- classmethod precision()¶
- Return type:
Literal['int8','fp16','fp32']
- classmethod prediction_out_idx()¶
- Return type:
int
- classmethod supports_encoding()¶
- Return type:
bool
- classmethod year_round_week_inputs()¶
- Return type:
tuple[float,...]
- class birdnet.geo.models.v3_0.tf.GeoTFBackendInt8V3_0(model_path, device_name, half_precision, **kwargs)¶
Bases:
TFBackend,VersionedGeoBackendProtocol- classmethod encoding_out_idx()¶
- Return type:
int|None
- classmethod in_idx()¶
- Return type:
int
- load()¶
- Return type:
None
- classmethod precision()¶
- Return type:
Literal['int8','fp16','fp32']
- classmethod prediction_out_idx()¶
- Return type:
int
- classmethod supports_encoding()¶
- Return type:
bool
- classmethod year_round_week_inputs()¶
- Return type:
tuple[float,...]
- class birdnet.geo.models.v3_0.tf.GeoTFDownloaderV3_0¶
Bases:
GeoDownloaderBaseV3_0- classmethod get_model_path_and_labels(lang, precision)¶
- Return type:
tuple[Path,OrderedSet[str]]
- birdnet.geo.models.v3_0.tf.check_tf_library_for_v3_0(library)¶
- Return type:
None
- birdnet.geo.models.v3_0.tf.check_tf_runtime_compatibility_for_v3_0(library)¶
- Return type:
None
birdnet.geo.models.v3_0.pb module¶
- class birdnet.geo.models.v3_0.pb.GeoPBBackendFP32V3_0(model_path, device_name, half_precision)¶
Bases:
PBBackend,VersionedGeoBackendProtocol- classmethod encoding_key()¶
- Return type:
str|None
- classmethod encoding_signature_name()¶
- Return type:
str|None
- classmethod input_key()¶
- Return type:
str
- classmethod precision()¶
- Return type:
Literal['int8','fp16','fp32']
- classmethod prediction_key()¶
- Return type:
str
- classmethod prediction_signature_name()¶
- Return type:
str
- classmethod supports_encoding()¶
- Return type:
bool
- classmethod year_round_week_inputs()¶
- Return type:
tuple[float,...]
- class birdnet.geo.models.v3_0.pb.GeoPBDownloaderV3_0¶
Bases:
GeoDownloaderBaseV3_0- classmethod get_model_path_and_labels(lang)¶
- Return type:
tuple[Path,OrderedSet[str]]
birdnet.geo.models.v3_0.pt module¶
- class birdnet.geo.models.v3_0.pt.GeoPTBackendFP32V3_0(model_path, device_name, half_precision, **kwargs)¶
Bases:
TorchBackend,VersionedGeoBackendProtocol- classmethod encoding_out_idx()¶
- Return type:
int|None
- classmethod precision()¶
- Return type:
Literal['int8','fp16','fp32']
- classmethod prediction_needs_sigmoid()¶
Whether the model’s prediction head returns logits instead of probabilities.
The exported TorchScript modules are not consistent about this: the acoustic model applies the activation itself, the geo model does not. Backends whose model returns logits declare it here so that all backends of a model yield the same probabilities.
- Return type:
bool
- classmethod prediction_out_idx()¶
- Return type:
int
- classmethod probe_input_size_samples()¶
- Return type:
int
- classmethod supports_encoding()¶
- Return type:
bool
- classmethod year_round_week_inputs()¶
- Return type:
tuple[float,...]
- class birdnet.geo.models.v3_0.pt.GeoPTDownloaderV3_0¶
Bases:
GeoDownloaderBaseV3_0- classmethod get_model_path_and_labels(lang, precision)¶
- Return type:
tuple[Path,OrderedSet[str]]
birdnet.geo.models.v3_0.onnx module¶
- class birdnet.geo.models.v3_0.onnx.GeoOnnxBackendFP16V3_0(model_path, device_name, half_precision, **kwargs)¶
Bases:
OnnxBackend,VersionedGeoBackendProtocol- classmethod encoding_out_idx()¶
- Return type:
int|None
- classmethod precision()¶
- Return type:
Literal['int8','fp16','fp32']
- classmethod prediction_out_idx()¶
- Return type:
int
- classmethod probe_input_size_samples()¶
- Return type:
int
- classmethod supports_encoding()¶
- Return type:
bool
- classmethod year_round_week_inputs()¶
- Return type:
tuple[float,...]
- class birdnet.geo.models.v3_0.onnx.GeoOnnxBackendFP32V3_0(model_path, device_name, half_precision, **kwargs)¶
Bases:
OnnxBackend,VersionedGeoBackendProtocol- classmethod encoding_out_idx()¶
- Return type:
int|None
- classmethod precision()¶
- Return type:
Literal['int8','fp16','fp32']
- classmethod prediction_out_idx()¶
- Return type:
int
- classmethod probe_input_size_samples()¶
- Return type:
int
- classmethod supports_encoding()¶
- Return type:
bool
- classmethod year_round_week_inputs()¶
- Return type:
tuple[float,...]
- class birdnet.geo.models.v3_0.onnx.GeoOnnxDownloaderV3_0¶
Bases:
GeoDownloaderBaseV3_0- classmethod get_model_path_and_labels(lang, precision)¶
- Return type:
tuple[Path,OrderedSet[str]]