Skip to content

[Bug] Granite 4.0 350M - H loading error #3550

@Sweaterdog

Description

@Sweaterdog
  1. Did you update? I am on the latest version of the docker container
  2. Colab or Kaggle or local / cloud local
  3. Number GPUs used, use nvidia-smi 1x RTX 3070
  4. Which notebook? Please link! N/A
  5. Which Unsloth version, TRL version, transformers version, PyTorch version? The latest
  6. Which trainer? SFTTrainer, GRPOTrainer etc SFTTrainer
model, tokenizer = FastLanguageModel.from_pretrained(
    model_name = "ibm-granite/granite-4.0-h-350m-base",
    max_seq_length = max_seq_length,
    dtype = dtype,
    load_in_4bit = False,
    full_finetuning = True, 
)

When that is run, this is the output:

RuntimeError: only Tensors of floating point dtype can require gradients

🦥 You can also ask via our Reddit page: https://www.reddit.com/r/unsloth/

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions