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

yolov8 + nebuly | AttributeError: type object 'DummyClass' has no attribute 'models' #342

Open
scraus opened this issue May 20, 2023 · 10 comments

Comments

@scraus
Copy link

scraus commented May 20, 2023

I tried reproducing the results in this notebook but I got the following errors:

image

@saim212
Copy link

saim212 commented Jun 1, 2023

I'm facing the same error any solution?

@vtl-btz
Copy link

vtl-btz commented Jun 12, 2023

Got the same problem.
As a workaround, you can use the previous speedster version
!pip install speedster==0.2.1

also, I can't find the latest speedster code in this repository. Maybe it exists only in PyPi

I'm facing the same error any solution?

@saim212
Copy link

saim212 commented Jun 15, 2023

Thanks for the response. now facing this issue.

     97         pred = [pred.cpu()]
     98     else:
---> 99         pred = [p.cpu() for p in pred]
    100     return pred
    101 

AttributeError: 'list' object has no attribute 'cpu'

Got the same problem. As a workaround, you can use the previous speedster version !pip install speedster==0.2.1

also, I can't find the latest speedster code in this repository. Maybe it exists only in PyPi

I'm facing the same error any solution?

@valeriosofi
Copy link
Collaborator

Hello, thank you for using speedster! We have just released speedster 0.4.0, where this issue is solved! Please update your local version by running pip install -U speedster and let me know if you have any other issues 😁

@saim212
Copy link

saim212 commented Jun 19, 2023

with speedster==0.4.0 still facing the same issue.
Screenshot from 2023-06-19 10-43-32

@saim212
Copy link

saim212 commented Jun 19, 2023

python -m nebullvm.installers.auto_installer --compilers all
the above command failed to install the following dependencies.

2023-06-19 05:30:44 | WARNING  | Unable to install torch_tensor_rt on this platform. The compiler will be skipped. 
2023-06-19 05:30:44 | INFO     | Trying to install faster_transformer on the platform...
2023-06-19 05:30:44 | WARNING  | Unable to install faster_transformer on this platform. The compiler will be skipped. 

@valeriosofi
Copy link
Collaborator

Hi @saim212, Can you share the notebook that you are using? I've just tried with the official one and It works correctly, you can try it here: YOLOv8 Notebook

@valeriosofi
Copy link
Collaborator

Hi @vtl-btz, you can find the speedster code here :)

Got the same problem. As a workaround, you can use the previous speedster version !pip install speedster==0.2.1

also, I can't find the latest speedster code in this repository. Maybe it exists only in PyPi

I'm facing the same error any solution?

@saim212
Copy link

saim212 commented Jun 19, 2023

Hi @saim212, Can you share the notebook that you are using? I've just tried with the official one and It works correctly, you can try it here: YOLOv8 Notebook

Hello @valeriosofi, I tested your notebook. It's working fine but I was trying to optimize the yolov8s-pose model. There I faced this issue.

@saim212
Copy link

saim212 commented Jun 19, 2023

For Yolov8-Pose model:

class YOLOWrapper(torch.nn.Module):
    def __init__(self, yolo_model):
        super().__init__()
        self.model = yolo_model.model
    
    def forward(self, x, *args, **kwargs):
        res = self.model(x)
        return res[0], *tuple(res[1][0])
        
model_wrapper = YOLOWrapper(yolo)

class OptimizedYOLO(torch.nn.Module):
    def __init__(self, optimized_model):
        super().__init__()
        self.model = optimized_model
    
    def forward(self, x, *args, **kwargs):
        res = self.model(x)
        return res[0], list(res[1][0:])
    
optimized_wrapper = OptimizedYOLO(optimized_model)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants