Comments (3)
I meet the same problem if ration_gin is not zero!
I meet the same problem if ration_gin is not zero!
我也是遇到的这个问题,然后我参考了文件ffc_resnet.py中实现BisicBlock类的做法,我使用三层ffc来代替原来的卷积层。
self.ffclayers = nn.Sequential(FFC(channels, channels, 3, 0, 0.75, stride=1, padding=1, dilation=1, groups=1, bias=False, enable_lfu=False), FFC(channels, channels, 3, 0.75, 0.75, stride=1, padding=1, dilation=1, groups=1, bias=False, enable_lfu=False), FFC(channels, self.out_channel, 3, 0.75, 0, stride=1, padding=1, dilation=1, groups=1, bias=False, enable_lfu=False), ConcatTupleLayer(),)
这里的ConcatTupleLayer()参考的 https://github.com/saic-mdal/lama
class ConcatTupleLayer(nn.Module): def forward(self, x): assert isinstance(x, tuple) x_l, x_g = x assert torch.is_tensor(x_l) or torch.is_tensor(x_g) if not torch.is_tensor(x_g): return x_l return torch.cat(x, dim=1)
class ConcatTupleLayer(nn.Module): def forward(self, x): assert isinstance(x, tuple) x_l, x_g = x assert torch.is_tensor(x_l) or torch.is_tensor(x_g) if not torch.is_tensor(x_g): return x_l return torch.cat(x, dim=1)
我在一个人脸修复任务中的开头的卷积层应用了快速傅里叶卷积,效果好像还彳亍。
from ffc.
I meet the same problem if ration_gin is not zero!
from ffc.
I meet the same problem if ration_gin is not zero!
I meet the same problem if ration_gin is not zero! 我也是遇到的这个问题,然后我参考了文件ffc_resnet.py中实现BisicBlock类的做法,我使用三层ffc来代替原来的卷积层。
self.ffclayers = nn.Sequential(FFC(channels, channels, 3, 0, 0.75, stride=1, padding=1, dilation=1, groups=1, bias=False, enable_lfu=False), FFC(channels, channels, 3, 0.75, 0.75, stride=1, padding=1, dilation=1, groups=1, bias=False, enable_lfu=False), FFC(channels, self.out_channel, 3, 0.75, 0, stride=1, padding=1, dilation=1, groups=1, bias=False, enable_lfu=False), ConcatTupleLayer(),)
这里的ConcatTupleLayer()参考的 https://github.com/saic-mdal/lama
class ConcatTupleLayer(nn.Module): def forward(self, x): assert isinstance(x, tuple) x_l, x_g = x assert torch.is_tensor(x_l) or torch.is_tensor(x_g) if not torch.is_tensor(x_g): return x_l return torch.cat(x, dim=1)
class ConcatTupleLayer(nn.Module): def forward(self, x): assert isinstance(x, tuple) x_l, x_g = x assert torch.is_tensor(x_l) or torch.is_tensor(x_g) if not torch.is_tensor(x_g): return x_l return torch.cat(x, dim=1)我在一个人脸修复任务中的开头的卷积层应用了快速傅里叶卷积,效果好像还彳亍。
感谢您耐心回复,对我解决bug很有帮助。希望未来能有机会和您进一步交流。
from ffc.
Related Issues (12)
- Could you provide the weights trained on imagenet? HOT 4
- TensorFlow 2 implementation
- ratio_gin and ratio_gout HOT 1
- Pretrained checkpoint
- FFC for keypoint detection and matching?
- Can not find torch.rfft in pytorch1.9 HOT 1
- Implementation on EfficientNet
- Could you provide the weights trained on imagenet? Thank you ! HOT 5
- BasicBlock implementation HOT 2
- Pretrained models doesn't match code HOT 2
- Missing license file HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ffc.