Skip to content

Commit

Permalink
added requirement
Browse files Browse the repository at this point in the history
  • Loading branch information
mrwyattii committed Jan 19, 2024
1 parent 71447a7 commit 682e904
Show file tree
Hide file tree
Showing 9 changed files with 23 additions and 16 deletions.
5 changes: 5 additions & 0 deletions benchmarks/inference/mii/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
transformers
matplotlib
deepspeed-mii>=0.2.0
vllm>=0.2.7
numpy
8 changes: 4 additions & 4 deletions benchmarks/inference/mii/src/client.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,10 @@
import numpy as np
from transformers import AutoTokenizer

from postprocess_results import ResponseDetails
from random_query_generator import RandomQueryGenerator
from sample_input import all_text
from utils import parse_args, print_summary, get_args_product, CLIENT_PARAMS
from .postprocess_results import ResponseDetails
from .random_query_generator import RandomQueryGenerator
from .sample_input import all_text
from .utils import parse_args, print_summary, get_args_product, CLIENT_PARAMS


def call_mii(client, input_tokens, max_new_tokens, stream):
Expand Down
2 changes: 1 addition & 1 deletion benchmarks/inference/mii/src/plot_effective_throughput.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import numpy as np
import pandas as pd

from postprocess_results import read_json, get_tokenizer
from .postprocess_results import read_json, get_tokenizer

RAGGED_BATCH_SIZE = 768
SLA_PROMPT_TOKENS_PER_SEC = 512
Expand Down
2 changes: 1 addition & 1 deletion benchmarks/inference/mii/src/plot_latency_percentile.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import numpy as np
import itertools

from postprocess_results import read_json, get_token_latency
from .postprocess_results import read_json, get_token_latency

bs = 768
SKIP_HEAD_TOKEN_NUM = 2
Expand Down
2 changes: 1 addition & 1 deletion benchmarks/inference/mii/src/plot_repl_scale.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from pathlib import Path
import numpy as np

from postprocess_results import read_json, get_summary
from .postprocess_results import read_json, get_summary

bs = 768

Expand Down
12 changes: 7 additions & 5 deletions benchmarks/inference/mii/src/plot_th_lat.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,16 @@

# DeepSpeed Team

import glob
import matplotlib.pyplot as plt
import argparse
from pathlib import Path
import numpy as np
from postprocess_results import read_json, get_summary
import glob
import os
import re
from pathlib import Path

import matplotlib.pyplot as plt
import numpy as np

from .postprocess_results import read_json, get_summary


def get_args():
Expand Down
2 changes: 1 addition & 1 deletion benchmarks/inference/mii/src/plot_tp_sizes.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from pathlib import Path
import numpy as np

from postprocess_results import read_json, get_summary
from .postprocess_results import read_json, get_summary

bs = 768

Expand Down
2 changes: 1 addition & 1 deletion benchmarks/inference/mii/src/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from deepspeed.inference import RaggedInferenceEngineConfig, DeepSpeedTPConfig
from deepspeed.inference.v2.ragged import DSStateManagerConfig

from utils import parse_args, SERVER_PARAMS
from .utils import parse_args, SERVER_PARAMS


def start_server(args):
Expand Down
4 changes: 2 additions & 2 deletions benchmarks/inference/mii/src/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
from pathlib import Path
from typing import Iterator, List

from defaults import ARG_DEFAULTS, MODEL_DEFAULTS
from postprocess_results import get_summary, ResponseDetails
from .defaults import ARG_DEFAULTS, MODEL_DEFAULTS
from .postprocess_results import get_summary, ResponseDetails

# For these arguments, users can provide multiple values when running the
# benchmark. The benchmark will iterate over all possible combinations.
Expand Down

0 comments on commit 682e904

Please sign in to comment.