Skip to content

I need to load my custom model from pre trained model #2

Description

@shaileshp367

Hello

I need to load my custom model from pre trained model

Here is the code but he giving error like 'HFValidationError: Repo id must use alphanumeric chars or '-', '_', '.', '--' and '..' are forbidden, '-' and '.' cannot start or end the name, max length is'

Please Help

model = "shaileshp/trained-test-model-1-merged"

dtype = torch.bfloat16 if torch.cuda.get_device_capability()[0] == 8 else torch.float16

model = AutoModelForCausalLM.from_pretrained(
model,
return_dict=True,
device_map="auto",
load_in_8bit=True,
torch_dtype=dtype,
#trust_remote_code=True,
)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions