Open tjasmin111 opened 1 year ago
describe more clearly
I mean, let's say I want to make some changes in the face landmarks like those beauty apps. For instance, to make nose smaller or lips bigger and such. How to achieve that?
Too easy!
Hmm can you please explain how? We can "get" the facemesh but how to use that to change the face landmarks?
My English is poor,do you know chinese?Can we communicate in Chinese?
or we can use the wchat
我不懂中文。 但你可以用中文解释,我可以使用谷歌翻译。 所以我的问题是,我们可以“获取”面部网格,但如何使用它来改变面部标志?
Perhaps you can perform some transformations on the pixels within a certain range around the landemarkes.
Why can you replay to me so quickly
Hehe because this is important to me. I need to know how to do it.
Are you working or studying
What kind of transformation? Can you write an example that gets facemesh and transforms nose?
I am an intern.
Oh, where are you from? Which school are you from
me,too
Ok! I'm in the US. California.
OK!What is your major,my main focus now is on computer vision and AI
What kind of transformation? Can you write an example that gets facemesh and transforms nose Can't your third stars solve your problem
Yes I'm a computer scientist focusing on computer vision. Do you think you can write a sample app to see how we can change landmark? What transformation should we use??
OK!I'll try to write it down.
Ok thanks. If we can do it for nose and make it smaller, then I can do it for all landmarks.
What time is it in your area
i think i can use the opencv todo it
It's 2:30am! And still awake, googling for this problem. I hope you can do it with opencv. So after knowing the mesh coordinates, you use opencv for transformation?
Some mesh deformation algorithms can be used, such as Laplacian deformation.
I need to know your specific task now.
Let's make nose smaller. That's the task.
How to use laplacian transformation? Should we pass the nose coordinates or the whole face mesh?
Let's make nose smaller. That's the task. The image or 3Dfile?
Prob image? Let's assume we stream from laptop camera.
Prob image? Let's assume we stream from laptop camera.
Image stream of camera?
Yeah, because imagine a person is trying to slim nose on his phone camera. Actually, it is 3D mesh of face bc we use facemesh.
Can you just make a small puthon code that make our nose look smaller?
import cv2 img = cv2.imred('./test.jpg') nose_mesh = [] new_width,new_height=a,b#a and b are the new width and height of the nose letf,right,top,bottom=nose_mesh[:,0].min(),nose_mesh[:,0].max(),nose_mesh[:,1].min(),nose_mesh[:,1].max() nose_np_array = img[top:bottom,left:right,:] new_nose_array = cv2.resize((new_width,new_height))
Did you test it? Can you please post How does the before and after image look?
use the 'Poisson Image Editing'
I didn't test it, just provided my ideas
Hmm you just get the area of nose and resize it. But how to stitch it with the face with no artifact? Please test it. I don't think it's that simple
use some image fusion algorithms
Just like 'Poisson Image Editing'.
Hmm poisson image editing fills the empty pixels with background image...yeah worth a try
Yes,you can have a try,there are some tutorials on Google that you can learn
May I ask how much your internship salary is ?
Hmm
Poisson algorithm needs a mask..not sure how to generate it. Internship is not much...40$/hr
It‘s so cool,mysalary is just10000¥ per month.
Country to country is different. If you come to US, you can get $50
That's true
Poisson algorithm needs a mask..not sure how to generate it. Internship is not much...40$/hr
The mask can be got by the nose area of mesh
But it shouldn't be a single mask. We have to run it continuously for camera. Face pose can change
The mask can be got by the nose area of mesh
Interesting project. Is it possible to use facemesh to change face and make nose smaller? How can I do that?