Git Product home page Git Product logo

cap_augmentation's People

Contributors

rocketflash avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

cap_augmentation's Issues

Birds Eye View

Hey, Nice Project. I was wondering about your implementation for generating birds eye view, will it be possible to provide work/links/documents that you referred for this conversion ? which can help me understand your implementation. I tried your code on my camera parameters and I get a black Image.

Regards

randint error

hey, first of all, great work, thank you.
I am getting this error;

ValueError: empty range for randrange() (0,0, 0)

which should mean there's a problem with the randint() function, mostly that in randint(a,b), b>a which somehow isn't the case here. can you help me with this?

question

Hello, I want konw you batch_size and input image_size

Something wrong about the semantic_mask and the instance_mask

Thanks for your great work.

But I encountered some problems when I run the code.
To be specific, there seems to be something wrong about the semantic_mask and the instance_mask.
The code can't draw instance(or semantic) segmentation image correctly.

image_dst, coords, mask = self.paste_object(image_dst, image_src, x_coord, y_coord, self.random_h_flip, self.random_v_flip)
if coords:
coords_all.append(coords)
x1,y1,x2,y2 = coords
curr_mask = mask/255
curr_mask = curr_mask.astype(np.uint8)
curr_mask_ins = curr_mask*idx
roi_mask_sem = semantic_mask[y1:y2, x1:x2]
roi_mask_ins = instance_mask[y1:y2, x1:x2]
mask_inv = cv2.bitwise_not(curr_mask*255)
img_sem_bg = cv2.bitwise_and(roi_mask_sem , roi_mask_sem, mask = mask_inv)
img_ins_bg = cv2.bitwise_and(roi_mask_ins , roi_mask_ins, mask = mask_inv)
dst_sem = cv2.add(img_sem_bg, curr_mask)
dst_ins = cv2.add(img_ins_bg, curr_mask_ins)
semantic_mask[y1:y2, x1:x2] = dst_sem
instance_mask[y1:y2, x1:x2] = dst_ins

I can't understand the logic stream in these codes above.

I try to modify them to the following:

image_dst, coords, mask = self.paste_object(image_dst, image_src, x_coord, y_coord, self.random_h_flip, self.random_v_flip)
if coords:
    coords_all.append(coords)
    x1, y1, x2, y2 = coords
    semantic_mask[y1:y2, x1:x2] = mask
    instance_mask[y1:y2, x1:x2] = mask*(idx+1)

And it's actually works.

So, I want to know more about the code snippet above. Can it work rensonably?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.