<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_viewport_profile(request_envelope):
 # type: (RequestEnvelope) -> ViewportProfile """Utility method, to get viewport profile. The viewport profile is calculated using the shape, current pixel width and height, along with the dpi. If there is no `viewport` value in `request_envelope.context`, then an `ViewportProfile.UNKNOWN_VIEWPORT_PROFILE` is returned. :param request_envelope: The alexa request envelope object :type request_envelope: ask_sdk_model.request_envelope.RequestEnvelope :return: Calculated Viewport Profile enum :rtype: ViewportProfile """

    viewport_state = request_envelope.context.viewport
    if viewport_state:
        shape = viewport_state.shape
        current_pixel_width = int(viewport_state.current_pixel_width)
        current_pixel_height = int(viewport_state.current_pixel_height)
        dpi = int(viewport_state.dpi)

        orientation = get_orientation(
            width=current_pixel_width, height=current_pixel_height)
        dpi_group = get_dpi_group(dpi=dpi)
        pixel_width_size_group = get_size(size=current_pixel_width)
        pixel_height_size_group = get_size(size=current_pixel_height)

        if (shape is Shape.ROUND
                and orientation is Orientation.EQUAL
                and dpi_group is Density.LOW
                and pixel_width_size_group is Size.XSMALL
                and pixel_height_size_group is Size.XSMALL):
            return ViewportProfile.HUB_ROUND_SMALL

        elif (shape is Shape.RECTANGLE
                and orientation is Orientation.LANDSCAPE
                and dpi_group is Density.LOW
                and pixel_width_size_group <= Size.MEDIUM
                and pixel_height_size_group <= Size.SMALL):
            return ViewportProfile.HUB_LANDSCAPE_MEDIUM

        elif (shape is Shape.RECTANGLE
                and orientation is Orientation.LANDSCAPE
                and dpi_group is Density.LOW
                and pixel_width_size_group >= Size.LARGE
                and pixel_height_size_group >= Size.SMALL):
            return ViewportProfile.HUB_LANDSCAPE_LARGE

        elif (shape is Shape.RECTANGLE
                and orientation is Orientation.LANDSCAPE
                and dpi_group is Density.MEDIUM
                and pixel_width_size_group >= Size.MEDIUM
                and pixel_height_size_group >= Size.SMALL):
            return ViewportProfile.MOBILE_LANDSCAPE_MEDIUM

        elif (shape is Shape.RECTANGLE
                and orientation is Orientation.PORTRAIT
                and dpi_group is Density.MEDIUM
                and pixel_width_size_group >= Size.SMALL
                and pixel_height_size_group >= Size.MEDIUM):
            return ViewportProfile.MOBILE_PORTRAIT_MEDIUM

        elif (shape is Shape.RECTANGLE
                and orientation is Orientation.LANDSCAPE
                and dpi_group is Density.MEDIUM
                and pixel_width_size_group >= Size.SMALL
                and pixel_height_size_group >= Size.XSMALL):
            return ViewportProfile.MOBILE_LANDSCAPE_SMALL

        elif (shape is Shape.RECTANGLE
                and orientation is Orientation.PORTRAIT
                and dpi_group is Density.MEDIUM
                and pixel_width_size_group >= Size.XSMALL
                and pixel_height_size_group >= Size.SMALL):
            return ViewportProfile.MOBILE_PORTRAIT_SMALL

        elif (shape is Shape.RECTANGLE
                and orientation is Orientation.LANDSCAPE
                and dpi_group >= Density.HIGH
                and pixel_width_size_group >= Size.XLARGE
                and pixel_height_size_group >= Size.MEDIUM):
            return ViewportProfile.TV_LANDSCAPE_XLARGE

        elif (shape is Shape.RECTANGLE
                and orientation is Orientation.PORTRAIT
                and dpi_group >= Density.HIGH
                and pixel_width_size_group is Size.XSMALL
                and pixel_height_size_group is Size.XLARGE):
            return ViewportProfile.TV_PORTRAIT_MEDIUM

        elif (shape is Shape.RECTANGLE
              and orientation is Orientation.LANDSCAPE
              and dpi_group >= Density.HIGH
              and pixel_width_size_group is Size.MEDIUM
              and pixel_height_size_group is Size.SMALL):
            return ViewportProfile.TV_LANDSCAPE_MEDIUM

    return ViewportProfile.UNKNOWN_VIEWPORT_PROFILE