Fix Qwen2 and SD (#441)

* fix qwen2

* version bump

* fix list shape
This commit is contained in:
Awni Hannun 2024-02-14 13:43:12 -08:00 committed by GitHub
parent e446598f62
commit 06ddb8414d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 2 additions and 3 deletions

View File

@ -19,7 +19,6 @@ class ModelArgs(BaseModelArgs):
num_key_value_heads: int = None
rope_theta: float = 1000000
rope_traditional: bool = False
model_type: str = None
rope_scaling: Optional[Dict[str, Union[float, str]]] = None
def __post_init__(self):

View File

@ -8,7 +8,7 @@ with open(Path(__file__).parent / "mlx_lm/requirements.txt") as fid:
requirements = [str(r) for r in pkg_resources.parse_requirements(fid)]
setup(
name="mlx-lm",
version="0.0.10",
version="0.0.11",
description="LLMs on Apple silicon with MLX and the Hugging Face Hub",
long_description=open("README.md", encoding="utf-8").read(),
long_description_content_type="text/markdown",

View File

@ -130,7 +130,7 @@ class StableDiffusion:
# Get the latents from the input image and add noise according to the
# start time.
x_0, _ = self.autoencoder.encode(image[None])
x_0 = mx.broadcast_to(x_0, [n_images] + x_0.shape[1:])
x_0 = mx.broadcast_to(x_0, (n_images,) + x_0.shape[1:])
x_T = self.sampler.add_noise(x_0, mx.array(start_step))
# Perform the denoising loop