2월 22일

문이빈·2023년 2월 27일
0

캡스톤디자인

목록 보기
1/1


안녕하세요!!

오늘은,,, 아침부터,,, 기숙사 짐을 빼고,,, 고단한 하루입니다!!

오늘 해볼 것은

BBA 알고리즘으로 ABR을 구현한 오픈소스를 이용해,

비디오 스트리밍 시 측정되는 주요 값들을 살펴볼 것입니다.

BBA 알고리즘에서 구현되는 버퍼 상태 변수와 선택되는 화질을 출력하는 것이 목표입니다.

이전에, 처리량 측정기를 통해, 비슷한 처리량임을 확인하고,
(즉,비슷한 네트워크 환경)에서 알고리즘 수정시 선택되는 화질이 더 높은 빈도로
높은 화질을 선택하는 것을 증명할 계획입니다.

알고리즘 수정 시에는 딥러닝이 적용될 계획입니다.

이 때, 버퍼 변수를 산출하는 과정에서, heuristic한 부분을 찾아 변경해보겠습니다.

코드

import matplotlib.pyplot as plt
import pandas as pd

#데이터 불러오기
df = pd.read_csv('buffer.txt', sep=' ', header=None)

#x, y1, y2 데이터 추출하기
x = df[0]
y1 = df[1]
y2 = df[2]

#그래프 그리기
fig, ax1 = plt.subplots()

#첫 번째 y축
color = 'tab:red'
ax1.set_xlabel('시간')
ax1.set_ylabel('버퍼상태', color=color)
ax1.plot(x, y1, color=color, label='버퍼상태')
ax1.tick_params(axis='y', labelcolor=color)

#두 번째 y축
ax2 = ax1.twinx()
color = 'tab:blue'
ax2.set_ylabel('화질', color=color)
ax2.plot(x, y2, color=color, label='화질')
ax2.tick_params(axis='y', labelcolor=color)

#범례 추가
lines1, labels1 = ax1.get_legend_handles_labels()
lines2, labels2 = ax2.get_legend_handles_labels()
ax2.legend(lines1 + lines2, labels1 + labels2, loc='upper center')

#그래프 출력
plt.show()

profile
문이빈

0개의 댓글