Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: 🐞 updating poetry lock file version and fixing numpy,pandas,maplotlib and python versions compatibility #1693

Merged
merged 10 commits into from
Dec 2, 2024

Conversation

onuralpszr
Copy link
Collaborator

@onuralpszr onuralpszr commented Nov 27, 2024

Description

  • I upgraded poetry to 1.8.4 and I got proper numpy version ( I make sure I delete poetry caches and everything and re-tried with warm cache and without cache and both works and I was able to import it)

Attempt to Fix #1688 and update CI tests for make sure we cover this test cases too

@onuralpszr onuralpszr self-assigned this Nov 27, 2024
@onuralpszr onuralpszr changed the title fix: 🐞 add poetry lock file re-generated via poetry 1.8.4 fix: 🐞 updating poetry lock file version and fixing numpy,pandas python3.13 problems Nov 27, 2024
@onuralpszr onuralpszr changed the title fix: 🐞 updating poetry lock file version and fixing numpy,pandas python3.13 problems fix: 🐞 updating poetry lock file version and fixing numpy,pandas,maplotlib and python versions compatibility Nov 27, 2024
@onuralpszr onuralpszr requested a review from LinasKo November 28, 2024 00:41
Signed-off-by: Onuralp SEZER <[email protected]>
@onuralpszr
Copy link
Collaborator Author

@LinasKo I fixed poetry installations for all versions and fixes for matplotlib,pandas too. I also include extra tests into CI such as "import test" and full pytest for each poetry envs. it should be better for good.

@onuralpszr onuralpszr added the bug Something isn't working label Nov 29, 2024
@LinasKo
Copy link
Contributor

LinasKo commented Dec 2, 2024

I've tested it, and I couldn't find anything wrong.

As an extra check, I verified that a relaxed-constraint version of inference can be installed and run alongside this.

pip install git+https://github.com/roboflow/inference.git@linas/allow-latest-rc-supervision
Test code
import cv2
import numpy as np
from inference import get_model
import supervision as sv


!wget -O dog.jpeg https://media.roboflow.com/notebooks/examples/dog.jpeg -q
image = cv2.imread("dog.jpeg")
assert image is not None

black_image = np.zeros_like(image)


box_model = get_model("yolov8n-640")
result = box_model.infer(image)[0]
detections = sv.Detections.from_inference(result)
assert len(detections) > 0

result = box_model.infer(black_image)[0]
detections = sv.Detections.from_inference(result)
assert len(detections) == 0


seg_model = get_model("yolov8n-seg-640")
result = seg_model.infer(image)[0]
detections = sv.Detections.from_inference(result)
assert len(detections) > 0

result = seg_model.infer(black_image)[0]
detections = sv.Detections.from_inference(result)
assert len(detections) == 0


kp_model = get_model("yolov8n-pose-640")
result = kp_model.infer(image)[0]

keypoints = sv.KeyPoints.from_inference(result)
assert len(keypoints) > 0

result = kp_model.infer(black_image)[0]
keypoints = sv.KeyPoints.from_inference(result)
assert len(keypoints) == 0

@LinasKo LinasKo merged commit d075eb1 into develop Dec 2, 2024
46 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Numpy incompatibility error, locally installed repo, Python 3.13
2 participants