def _prepare_init_params_from_job_description(cls, job_details, model_channel_name=None):
        """Convert the job description to init params that can be handled by the class constructor

        Args:
            job_details: the returned job details from a describe_training_job API call.
            model_channel_name (str): Name of the channel where pre-trained model data will be
                downloaded.

        Returns:
             dictionary: The transformed init_params
        """
        init_params = super(RLEstimator, cls)\
            ._prepare_init_params_from_job_description(job_details, model_channel_name)

        image_name = init_params.pop('image')
        framework, _, tag, _ = fw_utils.framework_name_from_image(image_name)

        if not framework:
            # If we were unable to parse the framework name from the image it is not one of our
            # officially supported images, in this case just add the image to the init params.
            init_params['image_name'] = image_name
            return init_params

        toolkit, toolkit_version = cls._toolkit_and_version_from_tag(tag)

        if not cls._is_combination_supported(toolkit, toolkit_version, framework):
            training_job_name = init_params['base_job_name']
            raise ValueError(
                "Training job: {} didn't use image for requested framework".format(
                    training_job_name)
            )

        init_params['toolkit'] = RLToolkit(toolkit)
        init_params['toolkit_version'] = toolkit_version
        init_params['framework'] = RLFramework(framework)

        return init_params
def _prepare_init_params_from_job_description ( cls , job_details , model_channel_name = None ) : init_params = super ( RLEstimator , cls ) . _prepare_init_params_from_job_description ( job_details , model_channel_name ) image_name = init_params . pop ( 'image' ) framework , _ , tag , _ = fw_utils . framework_name_from_image ( image_name ) if not framework : init_params [ 'image_name' ] = image_name return init_params toolkit , toolkit_version = cls . _toolkit_and_version_from_tag ( tag ) if not cls . _is_combination_supported ( toolkit , toolkit_version , framework ) : training_job_name = init_params [ 'base_job_name' ] raise ValueError ( "Training job: {} didn't use image for requested framework" . format ( training_job_name ) ) init_params [ 'toolkit' ] = RLToolkit ( toolkit ) init_params [ 'toolkit_version' ] = toolkit_version init_params [ 'framework' ] = RLFramework ( framework ) return init_params
Convert the job description to init params that can be handled by the class constructor

        Args:
            job_details: the returned job details from a describe_training_job API call.
            model_channel_name (str): Name of the channel where pre-trained model data will be
                downloaded.

        Returns:
             dictionary: The transformed init_params