sparsezoo
sparsezoo copied to clipboard
API for model.md, benchmark
Given a git-server url (model page url, git clone http or git clone ssh), load its metadata
url = "https://git.neuralmagic.com/neuralmagic/cary" \
or " [email protected]:neuralmagic/cary.git" \
or "https://git.neuralmagic.com/neuralmagic/cary.git"
server_model = GitServerModel(url)
server_model.benchmark.metadata # benchmark metadata
server_model.card.metadata # model.md metadata
Also can access attributes of each class.
server_model.card.domain # model.m's domain
server_model.card.optimizations # model.md's optimizations
server_model.card.task # model.md's task
# etc...
server_model.benchmark.deepsparse_version # deepsparse version
server_model.benchmark.model_commit_sha # commit sha of the model.onnx
# etc...
Model card looks like: https://git.neuralmagic.com/neuralmagic/cary/-/blob/main/model.md
Benchmark.yaml looks like: https://git.neuralmagic.com/neuralmagic/cary/-/blob/main/benchmark.yaml
@kazukageorge is this still in WIP mode?
Got comment to move the folder structure from git-server to general pathway