def FromFile(cls, path, actions_dict, resources_dict, file_format="yaml", name=None):
        """Create a RecipeObject from a file.

        The file should be a specially constructed yaml file that describes
        the recipe as well as the actions that it performs.

        Args:
            path (str): The path to the recipe file that we wish to load
            actions_dict (dict): A dictionary of named RecipeActionObject
                types that is used to look up all of the steps listed in
                the recipe file.
            resources_dict (dict): A dictionary of named RecipeResource types
                that is used to look up all of the shared resources listed in
                the recipe file.
            file_format (str): The file format of the recipe file.  Currently
                we only support yaml.
            name (str): The name of this recipe if we created it originally from an
                archive.
        """

        format_map = {
            "yaml": cls._process_yaml
        }

        format_handler = format_map.get(file_format)
        if format_handler is None:
            raise ArgumentError("Unknown file format or file extension", file_format=file_format, \
                known_formats=[x for x in format_map if format_map[x] is not None])
        recipe_info = format_handler(path)

        if name is None:
            name, _ext = os.path.splitext(os.path.basename(path))

        # Validate that the recipe file is correctly formatted
        try:
            recipe_info = RecipeSchema.verify(recipe_info)
        except ValidationError as exc:
            raise RecipeFileInvalid("Recipe file does not match expected schema", file=path, error_message=exc.msg, **exc.params)

        description = recipe_info.get('description')

        # Parse out global default and shared resource information
        try:
            resources = cls._parse_resource_declarations(recipe_info.get('resources', []), resources_dict)
            defaults = cls._parse_variable_defaults(recipe_info.get("defaults", []))

            steps = []
            for i, action in enumerate(recipe_info.get('actions', [])):
                action_name = action.pop('name')
                if action_name is None:
                    raise RecipeFileInvalid("Action is missing required name parameter", \
                        parameters=action, path=path)

                action_class = actions_dict.get(action_name)
                if action_class is None:
                    raise UnknownRecipeActionType("Unknown step specified in recipe", \
                        action=action_name, step=i + 1, path=path)

                # Parse out any resource usage in this step and make sure we only
                # use named resources
                step_resources = cls._parse_resource_usage(action, declarations=resources)
                fixed_files, _variable_files = cls._parse_file_usage(action_class, action)

                step = RecipeStep(action_class, action, step_resources, fixed_files)
                steps.append(step)

            return RecipeObject(name, description, steps, resources, defaults, path)
        except RecipeFileInvalid as exc:
            cls._future_raise(RecipeFileInvalid, RecipeFileInvalid(exc.msg, recipe=name, **exc.params),
                              sys.exc_info()[2])
Create a RecipeObject from a file.

        The file should be a specially constructed yaml file that describes
        the recipe as well as the actions that it performs.

        Args:
            path (str): The path to the recipe file that we wish to load
            actions_dict (dict): A dictionary of named RecipeActionObject
                types that is used to look up all of the steps listed in
                the recipe file.
            resources_dict (dict): A dictionary of named RecipeResource types
                that is used to look up all of the shared resources listed in
                the recipe file.
            file_format (str): The file format of the recipe file.  Currently
                we only support yaml.
            name (str): The name of this recipe if we created it originally from an
                archive.