question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Some puzzles on the cost volume

See original GitHub issue
for i in range(self.maxdisp/4):
            if i > 0 :
             cost[:, :refimg_fea.size()[1], i, :,i:]   = refimg_fea[:,:,:,i:]
             cost[:, refimg_fea.size()[1]:, i, :,i:] = targetimg_fea[:,:,:,:-i]
            else:
             cost[:, :refimg_fea.size()[1], i, :,:]   = refimg_fea
             cost[:, refimg_fea.size()[1]:, i, :,:]   = targetimg_fea

This piece of codes has puzzled me. I am wondering why there would be negtive numbers, if using range() ,should all the iteration be positive? Besides, I am also wondering the way to concat two feature maps. How to understand the last dimension where in code “if i > 0”, how to understand the index i: and :-i?

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

0reactions
JiaRenChangcommented, May 23, 2018

@kingsleyluoxin The region that we can not concatenate both left and right feature will be cut, and replace with 0.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Break-even Point Crossword Puzzle | AccountingCoach
Knowing how costs change as volume or activities change is helpful when making ... Some costs are mixed costs, which means partly fixed...
Read more >
The Six Major Puzzles in International Macroeconomics
Here, we show how costs of international trade can dramatically skew domestic consumption in favor of home-produced goods. Consider an extremely simple two- ......
Read more >
Menu Management: How to Control Restaurant Costs Dish by ...
Analyze your menu items — stars, plow horses, dogs, and puzzles — to understand where restaurant costs can be controlled and where more...
Read more >
Brain Games - Picture Puzzles #5: How Many Differences ...
Brain Games - Picture Puzzles #5: How Many Differences Can You Find? (Volume 5) ... The List Price is the suggested retail price...
Read more >
The value of a statistical life: some clarifications and puzzles
The value of a statistical life: some clarifications and puzzles - Volume 4 Issue 2. ... Implementing cost-benefit analysis when preferences are distorted....
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found