Namespace package providing infrastructure for Azure Cognitive Services Vision modules
npx @tessl/cli install tessl/pypi-azure-cognitiveservices-vision-nspkg@3.0.0A Python namespace package that provides the infrastructure for Azure Cognitive Services Vision modules. This package creates the azure.cognitiveservices.vision namespace hierarchy, allowing other Azure SDK packages to extend this namespace with their specific functionality.
pip install azure-cognitiveservices-vision-nspkgImportant: This package provides no direct imports and is not intended for direct usage. It serves purely as namespace infrastructure for other Azure Cognitive Services Vision packages.
The namespace is utilized indirectly when importing dependent packages:
# This package creates the namespace that enables these imports:
from azure.cognitiveservices.vision.computervision import ComputerVisionClient
from azure.cognitiveservices.vision.face import FaceClient
from azure.cognitiveservices.vision.customvision.training import CustomVisionTrainingClientThis package has no direct usage pattern as it contains no public API. It is automatically utilized when other Azure Cognitive Services Vision packages are installed and imported.
Examples of dependent packages that utilize this namespace infrastructure:
# Computer Vision package
from azure.cognitiveservices.vision.computervision import ComputerVisionClient
# Face Recognition package
from azure.cognitiveservices.vision.face import FaceClient
# Content Moderator package
from azure.cognitiveservices.vision.contentmoderator import ContentModeratorClient
# Custom Vision Training package
from azure.cognitiveservices.vision.customvision.training import CustomVisionTrainingClientEach of these imports is made possible by the namespace infrastructure provided by this package.
This package implements Python namespace packages using two different strategies:
pkgutil.extend_path()The namespace hierarchy created:
azure (root namespace)azure.cognitiveservices (cognitive services namespace)azure.cognitiveservices.vision (vision-specific namespace)This package provides the namespace infrastructure that enables other Azure Vision SDK packages to extend the azure.cognitiveservices.vision namespace.
No public API: This package exports no functions, classes, constants, or types for end-user consumption.
Namespace modules: Contains only __init__.py files with namespace extension code:
# Content of each __init__.py file:
__path__ = __import__('pkgutil').extend_path(__path__, __name__)Requires the broader Azure Cognitive Services namespace package:
azure-cognitiveservices-nspkg>=3.0.0This namespace package enables extension by packages such as:
azure-cognitiveservices-vision-computervision - Computer Vision API clientazure-cognitiveservices-vision-contentmoderator - Content Moderator API clientazure-cognitiveservices-vision-customvision - Custom Vision API clientazure-cognitiveservices-vision-face - Face API clientWhen these packages are installed, they extend the namespace created by this infrastructure package, allowing imports like from azure.cognitiveservices.vision.computervision import ...