def _translate_output(output):
 sensors_data_dict = {}
 sensors_data_array = output.split('\n\n')
 for sensor_data in sensors_data_array:
  sensor_data_dict = _process_sensor(sensor_data)
  if (not sensor_data_dict):
   continue
  sensor_type = _get_sensor_type(sensor_data_dict)
  sensor_id = sensor_data_dict['Sensor ID']
  if ('Sensor Reading' in sensor_data_dict):
   sensors_data_dict.setdefault(sensor_type, {})[sensor_id] = sensor_data_dict
 if (not sensors_data_dict):
  raise ipmiexcept.IPMIException(_('parse IPMI sensor data failed,No data retrieved from given input'))
 return sensors_data_dict

def _translate_output ( output ) : sensors_data_dict = { } sensors_data_array = output . split ( '\n\n' ) for sensor_data in sensors_data_array : sensor_data_dict = _process_sensor ( sensor_data ) if ( not sensor_data_dict ) : continue sensor_type = _get_sensor_type ( sensor_data_dict ) sensor_id = sensor_data_dict [ 'Sensor ID' ] if ( 'Sensor Reading' in sensor_data_dict ) : sensors_data_dict . setdefault ( sensor_type , { } ) [ sensor_id ] = sensor_data_dict if ( not sensors_data_dict ) : raise ipmiexcept . IPMIException ( _ ( 'parse IPMI sensor data failed,No data retrieved from given input' ) ) return sensors_data_dict
translate the return value into json dict .