[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y ] [Search | Free Show | Home]

Halp

This is a blue board which means that it's for everybody (Safe For Work content only). If you see any adult content, please report it.

Thread replies: 4
Thread images: 1

File: Capture.png (193KB, 916x389px) Image search: [Google]
Capture.png
193KB, 916x389px
So some of you may be aware of the following resource:

http://fotogenerator.npocloud.nl/

Essentially, some researchers made a neural network to turn a line drawing into a face.

This has great exploitation potential.

My goal is to be able to throw an arbitrary piece of line art in the input so that it can be processed. This will allow much more potential for inserting art, as the built-in editor is absolutely awful.

I have the following so far:

/*
* Throw the following code into the console at:
* http://fotogenerator.npocloud.nl/
*/

// select the canvas
var canvas = document.querySelector("#dekennisvannu canvas");

// grab a 2D drawing context
var ctx = canvas.getContext("2d");

// grab an image from a remote source
myimage = new Image();
// YOUR IMAGE GOES HERE
myimage.src = 'http://orig02.deviantart.net/f15e/f/2009/148/2/5/mizore_shirayuki_by_taylachan.jpg';

// Draw the image on the canvas, with the corner lined up.
// THIS WILL SCALE THE IMAGE TO FIT. Please give it a square image so it is not distorted.
ctx.drawImage(myimage, 140, 40, 256, 256);


This code will add the image to the right place in the right shape on the canvas.

However, the issue is that seemingly, any mouse move event on the document will reset the canvas, as if it is intentionally rejecting all content not drawn using the editor.

Things I know:

- the entire interface is drawn in the same canvas, so I can't just use jquery to click the "process" button without moving the mouse over to it.
- removing the mousemove handler prevents the entire interface from working

continued in post
>>
The source is available on Github. Download it, set it up and throw whatever input at it you'd like.
>>
>>60872655
I want to be able to send this to people without them having to get a working tensorflow distribution on their computer.
>>
>>60872885
Host a custom version yourself.
Thread posts: 4
Thread images: 1


[Boards: 3 / a / aco / adv / an / asp / b / bant / biz / c / can / cgl / ck / cm / co / cock / d / diy / e / fa / fap / fit / fitlit / g / gd / gif / h / hc / his / hm / hr / i / ic / int / jp / k / lgbt / lit / m / mlp / mlpol / mo / mtv / mu / n / news / o / out / outsoc / p / po / pol / qa / qst / r / r9k / s / s4s / sci / soc / sp / spa / t / tg / toy / trash / trv / tv / u / v / vg / vint / vip / vp / vr / w / wg / wsg / wsr / x / y] [Search | Top | Home]

I'm aware that Imgur.com will stop allowing adult images since 15th of May. I'm taking actions to backup as much data as possible.
Read more on this topic here - https://archived.moe/talk/thread/1694/


If you need a post removed click on it's [Report] button and follow the instruction.
DMCA Content Takedown via dmca.com
All images are hosted on imgur.com.
If you like this website please support us by donating with Bitcoins at 16mKtbZiwW52BLkibtCr8jUg2KVUMTxVQ5
All trademarks and copyrights on this page are owned by their respective parties.
Images uploaded are the responsibility of the Poster. Comments are owned by the Poster.
This is a 4chan archive - all of the content originated from that site.
This means that RandomArchive shows their content, archived.
If you need information for a Poster - contact them.