Skip to content

Conversation

@Geo99pro
Copy link

@Geo99pro Geo99pro commented Mar 24, 2025

Hi everyone,

I hope you're all doing well!

First of all, I would like to congratulate you all on the amazing work you've done and made available to the community. It’s truly impressive!

@JulioZhao97, I encountered an issue when trying to fine-tune the model on custom data. Specifically, the model was unable to perform the final validation step after training.

This issue seems related to previous reports from other users. For example, the issue mentioned in #72.

After some debugging sessions, I made updates to the code to address this problem.

🆕 I've also added a Dockerfile, in case anyone wants to use it.

I hope my contribution is helpful and adds value to your excellent project.

Looking forward to your feedback!

Best regards,

Geo99pro added 19 commits March 24, 2025 09:01
@JulioZhao97
Copy link
Member

@Geo99pro Hello! Thanks for your contribution, I will review your PR and give responses within this week (sorry for that cause I am kind of busy)

@Geo99pro
Copy link
Author

@Geo99pro Hello! Thanks for your contribution, I will review your PR and give responses within this week (sorry for that cause I am kind of busy)

Hi sir @JulioZhao97, There is no problem, i can understand it. I make myself available anytime.

Comment on lines +38 to +44
if hasattr(self.dcv, "bn") and self.dcv.bn is not None:
bn = self.dcv.bn
x = bn(F.conv2d(x, weight, stride=1, padding=padding, dilation=dilation))
else:
x = F.conv2d(x, weight, stride=1, padding=padding, dilation=dilation)

return act(x) # Apply activation function
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sir @JulioZhao97 I did this because while debugging, I noticed that in: https://github.com/opendatalab/DocLayout-YOLO/blob/main/doclayout_yolo/nn/tasks.py more specifically in the fuse function (line 180) you merge the Conv2d() and the BatchNorm2d() whose purpose is to speed up inference. Since you delete after the bn, the model undergoes this alteration. I could be wrong, but it will be a pleasure to learn from you.

…ile by simplifying the COPY and WORKDIR instructions. Enable the use of requirements file to install only the necessary library instead of the biblio.
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hello sir @JulioZhao97, I've added a requirements file to better manage the dependencies that will make it easy to use docker.

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

Successfully merging this pull request may close these issues.

2 participants