Comments (1)
LayoutNet is almost the same as Discriminator, except for where the fake samples come from. The code looks like below.
# fake layout generation
if random.random() < 0.5:
data.x = data.x + torch.normal(0, 0.05, size=data.x.size())
is_real = torch.zeros(batch_size)
else:
is_real = torch.ones(batch_size)
...
# loss computation
loss_bce = F.binary_cross_entropy_with_logits(logit_disc, is_real)
loss_recl = F.cross_entropy(logit_cls, data.y)
loss_recb = F.mse_loss(bbox_pred, data.x)
loss = loss_bce + loss_recl + 10 * loss_recb
from const_layout.
Related Issues (20)
- python generate.py提示内存溢出,但内存确实是充足的,大家有遇到相似情况吗 HOT 1
- ModuleNotFoundError: No module named 'torch',auther can add "torch" to requirement.txt HOT 1
- about the train loss HOT 2
- Why add "to_dense_batch" to process the location information x and category label y? HOT 1
- CUDA error: CUBLAS_STATUS_EXECUTION_FAILED when calling cublasSgemm HOT 1
- How to train the model on local PC HOT 1
- furniture placement HOT 1
- Potential issue in max_iou computation HOT 4
- Unable to reproduce the CLG-LO HOT 2
- How to keep aspect ratio during optimization? HOT 1
- how to use the model with local dataset?
- How to specify relation constraints?
- Quantitative comparison of unconstrained layout generation HOT 4
- When I input ./download_model.sh, it runs like this...WHY HOT 2
- data link is in 404 status, how can i get the train data? HOT 2
- 7.Install ImageMagick for visualization can it be more detailed? HOT 2
- Key error with constrained generation HOT 2
- assert data.attr[0]['has_canvas_element'] HOT 2
- How to change number of elements? 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 const_layout.