Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ jobs:
- name: Install dependencies
run: |
pip install -e .
pip install pytest==6.1.1 torchvision scikit-learn gorilla transformers torchtext matplotlib captum
pip install pytest==7.2.1 torchvision scikit-learn gorilla transformers torchtext matplotlib captum

- name: Install pytorch lightning
run: |
Expand Down
6 changes: 3 additions & 3 deletions mlflow_torchserve/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,9 +22,9 @@
_DEFAULT_TORCHSERVE_LOCAL_MANAGEMENT_PORT = "8081"


class CustomPredictionsResponse(PredictionsResponse):
class TorchServePredictionsResponse(PredictionsResponse):
def __init__(self, resp):
super(CustomPredictionsResponse, self).__init__(self)
super(TorchServePredictionsResponse, self).__init__(self)
self.resp = resp

def to_json(self, path=None):
Expand Down Expand Up @@ -299,7 +299,7 @@ def predict(self, deployment_name, df):
raise ValueError("Unable to parse input json string: {}".format(e))

resp = requests.post(url, data)
cust_resp = CustomPredictionsResponse(resp.text)
cust_resp = TorchServePredictionsResponse(resp.text)
if resp.status_code != 200:
raise Exception(
"Unable to infer the results for the name %s. "
Expand Down