parameters: (self, coordinates)
return_statement: return (conversion_status, decimal_degrees_coordinates)
docstring: Performs a coordinate transformation from DMS format to DD.
  
      Valid coordinates in DMS format are as below:
        Latitude: 49(degrees)32(minutes)10.76(seconds) N
        Longitude: 131(degrees)9(minutes)22.34(seconds) E
  
        Latitude: 19(degrees)11(minutes)0.789(seconds) S
        Longitude: 89(degrees)59(minutes) 12.23456(seconds) W
  
      Invalid values are:
        Latitude: 74(degrees)22.876(minutes)25(seconds) N
        Longitude: 131(degrees)99(minutes)34.56(seconds) W
  
        Latitude: 19(degrees)11(minutes)23.789(seconds) W
        Longitude: 89(degrees)59(minutes)11.23(seconds) S
  
      Latitude's in Southern Hemisphere take negative values and those
      in Nothern, positive
      Longitude's in Western Hemisphere take negative values and those
      in Eastern, positive
  
      Args:
       coordinates: List of coordinates in DMS(Degrees, Minutes, Seconds) format.
      Returns:
       tuple containing
        conversion_status: Whether format conversion to decimal degrees succeeded.
        decimal_degrees_coordinates: List of coordinates in DD(Decimal Degrees)
         format.
docstring_summary: Performs a coordinate transformation from DMS format to DD.
docstring_tokens: Performs a coordinate transformation from DMS format to DD .
function: def TransformDMSToDD(self, coordinates):
      """Performs a coordinate transformation from DMS format to DD.
  
      Valid coordinates in DMS format are as below:
        Latitude: 49(degrees)32(minutes)10.76(seconds) N
        Longitude: 131(degrees)9(minutes)22.34(seconds) E
  
        Latitude: 19(degrees)11(minutes)0.789(seconds) S
        Longitude: 89(degrees)59(minutes) 12.23456(seconds) W
  
      Invalid values are:
        Latitude: 74(degrees)22.876(minutes)25(seconds) N
        Longitude: 131(degrees)99(minutes)34.56(seconds) W
  
        Latitude: 19(degrees)11(minutes)23.789(seconds) W
        Longitude: 89(degrees)59(minutes)11.23(seconds) S
  
      Latitude's in Southern Hemisphere take negative values and those
      in Nothern, positive
      Longitude's in Western Hemisphere take negative values and those
      in Eastern, positive
  
      Args:
       coordinates: List of coordinates in DMS(Degrees, Minutes, Seconds) format.
      Returns:
       tuple containing
        conversion_status: Whether format conversion to decimal degrees succeeded.
        decimal_degrees_coordinates: List of coordinates in DD(Decimal Degrees)
         format.
      """
  
      conversion_status = False
      is_valid_latitude = False
      is_valid_longitude = False
  
      decimal_degrees_coordinates = []
  
      self._logger.debug(
          "Performing DMS to DD transformation on coordinates %s, %s.",
          coordinates[0], coordinates[1])
  
      for (iteration, coordinate) in enumerate(coordinates):
        matched = re.match(self._dms_pattern, coordinate)
        if matched:
          try:
            (degrees, minutes, seconds, direction) = matched.groups()
  
            decimal_degrees = (
                float(degrees) + (
                    (float(minutes) * CoordinateTransform.MINUTES_UNITS) +
                    float(seconds))/CoordinateTransform.SECONDS_UNITS)
  
            if direction in self._dms_negative_directions:
              decimal_degrees = -decimal_degrees
  
            if iteration == 0 and direction in self._valid_latitude_directions:
              is_valid_latitude = True
            if iteration == 1 and direction in self._valid_longitude_directions:
              is_valid_longitude = True
  
            decimal_degrees_coordinates.append(decimal_degrees)
          except ValueError, e:
            self._logger.error(
                "DMS coordinates %s not in proper format, %s.", coordinate, e)
  
      conversion_status = is_valid_latitude and is_valid_longitude
  
      return (conversion_status, decimal_degrees_coordinates)
function_tokens: def TransformDMSToDD ( self , coordinates ) : conversion_status = False is_valid_latitude = False is_valid_longitude = False decimal_degrees_coordinates = [ ] self . _logger . debug ( "Performing DMS to DD transformation on coordinates %s, %s." , coordinates [ 0 ] , coordinates [ 1 ] ) for ( iteration , coordinate ) in enumerate ( coordinates ) : matched = re . match ( self . _dms_pattern , coordinate ) if matched : try : ( degrees , minutes , seconds , direction ) = matched . groups ( ) decimal_degrees = ( float ( degrees ) + ( ( float ( minutes ) * CoordinateTransform . MINUTES_UNITS ) + float ( seconds ) ) / CoordinateTransform . SECONDS_UNITS ) if direction in self . _dms_negative_directions : decimal_degrees = - decimal_degrees if iteration == 0 and direction in self . _valid_latitude_directions : is_valid_latitude = True if iteration == 1 and direction in self . _valid_longitude_directions : is_valid_longitude = True decimal_degrees_coordinates . append ( decimal_degrees ) except ValueError , e : self . _logger . error ( "DMS coordinates %s not in proper format, %s." , coordinate , e ) conversion_status = is_valid_latitude and is_valid_longitude return ( conversion_status , decimal_degrees_coordinates )