microsoft / microsoft/OmniParser
No such file or directory: 'weights/icon_caption_florence/configuration_florence2.py'
Nobody has claimed this yet.
- Dominant language
- Jupyter Notebook
- Stars
- 25.4k
- Forks
- 2.2k
- PR merge metrics
- No merged PRs in 30d
Description
When I run the model, the error shows that 'No such file or directory: 'weights/icon_caption_florence/configuration_florence2.py''. I checked the model downloaded from HF, and it does not contain the file 'configuration_florence2.py'.
However, I found that the file 'configuration_florence2.py' is a sub-file of 'microsoft/Florence-2-base'. I changed the code below, using 'microsoft/Florence-2-base' instead of model_name_or_path, and the project was able to run successfully.
Code: model = AutoModelForCausalLM.from_pretrained(model_name_or_path, torch_dtype=torch.float16, trust_remote_code=True).to(device)
The test result is unexpected; common icons cannot be recognized.
I look forward to your answer. Thank you.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the model loading call using AutoModelForCausalLM.from_pretrained and compare model_name_or_path with microsoft/Florence-2-base. Inspect the downloaded weights/icon_caption_florence contents and the referenced configuration_florence2.py path; done means the project loads the intended model without the missing-file error and icon recognition behaves as expected.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- huggingface, python, pytorch
- Domain
- computer-vision, machine-learning
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100