Common package
- super_gradients.common.explicit_params_validation(function: Optional[Callable] = None, validation_type: str = 'None')[source]
- super_gradients.common.singleton(cls)[source]
A singleton decorator. Returns a wrapper objects. A call on that object returns a single instance object of decorated class. Use the __wrapped__ attribute to access decorated class directly in unit tests
- class super_gradients.common.AWSConnector[source]
Bases:
object
AWSConnector - Connects to AWS using Credentials File or IAM Role
- static get_aws_session(profile_name: str) → boto3.session.Session[source]
- get_aws_session - Connects to AWS to retrieve an AWS Session
- param profile_name
The Config Profile (Environment Name in Credentials file)
- return
boto3 Session
- static get_aws_client_for_service_name(profile_name: str, service_name: str) → boto3.session.Session.client[source]
- get_aws_client_for_service_name - Connects to AWS to retrieve the relevant Client
- param profile_name
The Config Profile (Environment Name in Credentials file)
- param service_name
The AWS Service name to get the Client for
- return
Service client instance
- static get_aws_resource_for_service_name(profile_name: str, service_name: str) → boto3.session.Session.resource[source]
- Connects to AWS to retrieve the relevant Resource (More functionality then Client)
- param profile_name
The Config Profile (Environment Name in Credentials file)
- param service_name
The AWS Service name to get the Client for
- return
Service client instance
- class super_gradients.common.DatasetDataInterface(env: str, data_connection_source: str = 's3')[source]
Bases:
object
- load_remote_dataset_file()
- class super_gradients.common.ADNNModelRepositoryDataInterfaces(data_connection_location: str = 'local', data_connection_credentials: Optional[str] = None)[source]
Bases:
super_gradients.common.abstractions.abstract_logger.ILogger
ResearchModelRepositoryDataInterface
- load_all_remote_log_files()
- save_all_remote_checkpoint_files()
- load_remote_checkpoints_file()
- load_remote_logging_files()
- save_remote_checkpoints_file()
- save_remote_tensorboard_event_files()
- class super_gradients.common.S3Connector(env: str, bucket_name: str)[source]
Bases:
super_gradients.common.abstractions.abstract_logger.ILogger
S3Connector - S3 Connection Manager
- check_key_exists()
- get_object_by_etag()
- create_bucket()
- delete_bucket()
- get_object_metadata()
- delete_key()
- upload_file_from_stream()
- upload_file()
- download_key()
- download_keys_by_prefix()
- download_file_by_path()
- empty_folder_content_by_path_prefix()
- upload_buffer()
- list_bucket_objects()
- create_presigned_upload_url()
- create_presigned_download_url()
- copy_key()
- super_gradients.common.init_trainer()[source]
a function to initialize the super_gradients environment. This function should be the first thing to be called by any code running super_gradients. It resolves conflicts between the different tools, packages and environments used and prepares the super_gradients environment.