Views
No views yet

1from transformers import AutoProcessor, AutoModel
2
3# Load processor
4processor = AutoProcessor.from_pretrained("Laudando-Associates-LLC/d-fine", trust_remote_code=True)
5
6# Load model
7model = AutoModel.from_pretrained("Laudando-Associates-LLC/d-fine-large", trust_remote_code=True)
8
9# Process image
10inputs = processor(image)
11
12# Run inference
13outputs = model(**inputs, conf_threshold=0.4)D-FINE or its methods in your work, please cite the following BibTeX entries:1@misc{peng2024dfine,
2 title={D-FINE: Redefine Regression Task in DETRs as Fine-grained Distribution Refinement},
3 author={Yansong Peng and Hebei Li and Peixi Wu and Yueyi Zhang and Xiaoyan Sun and Feng Wu},
4 year={2024},
5 eprint={2410.13842},
6 archivePrefix={arXiv},
7 primaryClass={cs.CV}
8}