Skip to content

Commit

Permalink
fix(llm): remove unnecessary check (#683)
Browse files Browse the repository at this point in the history
Signed-off-by: Aaron <29749331+aarnphm@users.noreply.github.com>
  • Loading branch information
aarnphm authored Nov 17, 2023
1 parent 10471f7 commit 381d740
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion openllm-python/src/openllm/_llm.py
Original file line number Diff line number Diff line change
Expand Up @@ -222,7 +222,7 @@ def _torch_dtype(self):
if config_dtype is None:
config_dtype = torch.float32
if self.__llm_torch_dtype__ == 'auto':
if config_dtype == torch.float32 and torch.cuda.is_available():
if config_dtype == torch.float32:
torch_dtype = torch.float16 # following common practice
else:
torch_dtype = config_dtype
Expand Down

0 comments on commit 381d740

Please sign in to comment.