Jump to content
 

Creating printable little people in 5 minutes using just the internet


Recommended Posts

 

 

UPDATE  : USE THIS LINK RATHER THAN THE ORIGINAL ONE IN THE THREAD, IT IS A MORE RECENT UPDATE OF THE ORIGINAL PIFUHD COLAB:

https://colab.research.google.com/drive/1gYiwvvmAhjg1nDNjN8kv6L9eOsbP-9w-?usp=sharing

 

 

Step 1: Go here:

 

https://colab.research.google.com/drive/1NzP4oI_KighbpfEEVCnYKZ0lfzDpqTyE?usp=sharing

 

Step 2: Scroll down and click litle triangle beside Step1 to run this cell:

 

1.jpg.8524c4ee7ba6b9169eccb4ab0e3c9584.jpg 

 

 

This may take a few minutes depending on how speedy your machine is.

 

Step 3:

 

Do a Google search for suitable figure. Need to be front facing and no background for best results eg:

 

"goth girl standing no background"

 

Choose suitable image eg:

 

image.png.007b1250b72cf26ee1bdf687fc967a96.png

 

Right click on resulting image and click on "Copy Image Address"

 

Step 4:

 

Paste URL into field:

 

2.jpg.fe9f1565c336a900cac7ef6d9c94b80f.jpg

 

Step 5:

 

Click triangle beside STEP2 to run. If you get an error saying something like "Resolving $image_url ($image_url)... failed: Name or service not known"  then show code and go to the following line:

 

!wget '$image_url' -O '$path'

 

and remove the 4 apostrophes, then try again. 

 

When complete a  short animation should show the results, press play to rotate :

 

1526992938_Screenshot(578).png.a0e7ae48d863f4a366e2825c8435f1a5.png

 

Step 6:

 

Select "Execute to download the 3D model (.obj file) (From web image)" to download .obj file.

 

 

Step 7:

 

Import into Meshmixer, Blender or whatever to cleanup  any issues and to rescale for printing.

538715853_Screenshot(579).png.f8f87b598422b80041a1e72e7f5fde25.png

 

 

 

To do more, just insert new url into field on right hand side of  Step 2:

 

636540488_Screenshot(580).png.c3455e124d0924c211eddb71584c8bdd.png

 

 

There is also an "upload image" section further down the page, I haven't tried it but in theory it should be possible to find suitable period or particular occupation images, remove background in gimp or photoshop and use them via that section. 

 

Or do yourself, your family and friends. ( Not pets but, it only works with humans..).

 

 

Step 8:

 

Populate your layout with whoever you like!

1601980644_Screenshot(581).png.ed2bd2dd01597afde35f35b9097f124c.png

 

 

Edited by monkeysarefun
  • Like 8
  • Informative/Useful 10
Link to post
Share on other sites

  • monkeysarefun changed the title to Creating printable little people in 5 minutes using just the internet
17 minutes ago, simonmcp said:

Does it make up a reasonable looking back to the figures or are they only one sided?

It uses AI to create a fully formed 3D figure. It sometimes gets it a little wrong, such as adding high heels to a male figure but other than that the results are good enough to print at the scales we use, at least on par with whitemetal figures for detail and finish.

 

I'll hunt out the YouTube video that ran through it in more detail later.

  • Like 1
  • Thanks 1
Link to post
Share on other sites

  • RMweb Premium

This is pretty impressive stuff.  It doesn't look to have been worked on for 3 years, at least not in this public collaboration.  I've managed to get some quite usable figures out of it even just using the 512x512 low res image test mode.  Being a research project, and 3 years old, installing the software on your own machine is a little challenging and it took me several hours of tinkering to get it working but it was worth the effort.

 

I'm particularly looking for figures for Edwardian era through to the early 1920s and there really isn't a lot of convincing models available off the shelf.  So to the internet...

 

This is an image from Shutterstock adjusted to be 512x512 with the extra bits down the side just plain black...

 

Lady3_test.jpg.2409b45ad5a84684574716f85ac3cf6f.jpg

 

...and here she is printed to 7mm scale with a very crude paint job:

 

20230309_155233.jpg.2970df2e0ab61bcdc98ba43a0bf5b380.jpg

 

A bit more work on the painting and it's a usable figure.  As you can see the algorithm doesn't recognise a stack of books so her hands are empty!

 

As to what happens at the back, well here are a selection of models I created yesterday:

 

20230309_155826.jpg.7364032c28bca3731a43d276c2f90b44.jpg

 

and from the rear:

 

20230309_155900.jpg.c875c3dd057a64e97a3389a87ea4480c.jpg

 

As you can see the algorithms struggle with long skirts but there is nothing that can't be fixed with a dab of filler.  On the other hand the gent in the suit is pretty much spot on.  His face is a bit blurred because he had a beard but overall it's pretty good and certainly good enough for a background figure.

 

If you try more modern figures then the reverse modelling is very good for both male and female clothing.  I can see myself using this quite a lot and maybe reading the research papers and looking at extending the capabilities (there's nothing on the telly!).

 

Cheers

Dave

 

  • Like 4
  • Agree 1
  • Informative/Useful 1
  • Craftsmanship/clever 1
Link to post
Share on other sites

This first  video is an overview and uses a   different workflow from my original post 

 

The second video covers it a little deeper  if anyone needs a bit more troubleshooting etc.

 

 

 

7 hours ago, eldavo said:

As you can see the algorithms struggle with long skirts but there is nothing that can't be fixed with a dab of filler

 

 

Meshmixer (free)  is capable of importing the .obj file and using its sculpting tools to fill out or smooth out any details. There are heaps of tutorials online if needed. Blender too, though the interface is intimidating at first...

Edited by monkeysarefun
  • Like 1
  • Informative/Useful 2
Link to post
Share on other sites

This is really cool, I been thinking about looking into some of the free human generating software out there in attempt to knock up some peeps, I know a few others have looked at it before, but nailing this workflow, and output would be awesome will have a gander thanks for posting guys

  • Like 1
Link to post
Share on other sites

16 hours ago, rovex said:

Being a bear of little brain I don't suppose someone could help me with either of these.

I need a larger version of the prieser ho version to sit a top my court house

 

IMG_20230312_013518.jpg.e069dd843ffd7dae9e3af84733ea153a.jpg155553781_or-la-dame-de-bronze-statue-de-la-justice-a-l-epee-et-d-une-balance-au-dessus-de-la-cour-criminelle-centrale-old-bailey-london-cx85mn2.jpg.ac4950b9e5aa078aa6b9e43db23337c0.jpg

 

 

IF you dont need that one in particular you can get a slightly different version as a free downloadable .stl file from thingiverse...

 

 

 

https://www.thingiverse.com/thing:4153723/files

 

(or put suitable terms such as Justice, Themis etc into yeggi.com, but many will not be free and others look like they were designed by dirty old men!....) 

Edited by monkeysarefun
  • Like 1
Link to post
Share on other sites

On 09/03/2023 at 16:30, eldavo said:

This is pretty impressive stuff.  It doesn't look to have been worked on for 3 years, at least not in this public collaboration.  I've managed to get some quite usable figures out of it even just using the 512x512 low res image test mode.  Being a research project, and 3 years old, installing the software on your own machine is a little challenging and it took me several hours of tinkering to get it working but it was worth the effort.

 

I'm particularly looking for figures for Edwardian era through to the early 1920s and there really isn't a lot of convincing models available off the shelf.  So to the internet...

 

This is an image from Shutterstock adjusted to be 512x512 with the extra bits down the side just plain black...

 

Lady3_test.jpg.2409b45ad5a84684574716f85ac3cf6f.jpg

 

...and here she is printed to 7mm scale with a very crude paint job:

 

20230309_155233.jpg.2970df2e0ab61bcdc98ba43a0bf5b380.jpg

 

A bit more work on the painting and it's a usable figure.  As you can see the algorithm doesn't recognise a stack of books so her hands are empty!

 

As to what happens at the back, well here are a selection of models I created yesterday:

 

20230309_155826.jpg.7364032c28bca3731a43d276c2f90b44.jpg

 

and from the rear:

 

20230309_155900.jpg.c875c3dd057a64e97a3389a87ea4480c.jpg

 

As you can see the algorithms struggle with long skirts but there is nothing that can't be fixed with a dab of filler.  On the other hand the gent in the suit is pretty much spot on.  His face is a bit blurred because he had a beard but overall it's pretty good and certainly good enough for a background figure.

 

If you try more modern figures then the reverse modelling is very good for both male and female clothing.  I can see myself using this quite a lot and maybe reading the research papers and looking at extending the capabilities (there's nothing on the telly!).

 

Cheers

Dave

 

I would be interested to know the detailed steps that you went through to install this, as I am struggling to say the least. I get errors around finding and installing the correct dependencies.

 

I would like to use this to salvage some photogrammetry projects where the end result is less than optimal due to lots of plain colours preventing accurate image matching, or just poor photography in the first place!

 

Any assistance gratefully received and I will happily share the resulting files with the wider community.  

Link to post
Share on other sites

19 hours ago, noiseboy72 said:

I would be interested to know the detailed steps that you went through to install this, as I am struggling to say the least. I get errors around finding and installing the correct dependencies.

 

I would like to use this to salvage some photogrammetry projects where the end result is less than optimal due to lots of plain colours preventing accurate image matching, or just poor photography in the first place!

 

Any assistance gratefully received and I will happily share the resulting files with the wider community.  

Hey mate,

 

The collab link in this videos description is to a much more recent iteration  than the one I posted originally, its from last week so it should  hopefully fix some of the broken paths etc that the 3 year old one I posted threw up at times. I havent tried it myself. to confirm though.

 

Failing that if you have an Nvidia graphics card you  could try creating a local copy, again I havent done that myself yet but I plan to when I get a chance over the next couple of days. If I get it working I'll post instructions.  Cheers!

 

 

  • Thanks 1
  • Informative/Useful 1
Link to post
Share on other sites

Thanks for the reply.

I did precisely that, and got it to work well enough to download the .Obj files, even if the pointless video animation didn't work. 

 

Not sure my Python skills are up to putting this together as an on-machine version, but let me know how you get on!

Link to post
Share on other sites

37 minutes ago, noiseboy72 said:

even if the pointless video animation didn't work. 

 Yeah I think thats because it fails to install pytorch3d but no real loss, like you said the .obj file still gets created.

 

Heres a couple of tests I just did using that collab with a couple of images I found for Edwardian costumes on Etsy, works ok.

 

699748558_Screenshot(587).png.e82dc4f965ed616cda5aefb1fc80fbe4.png

 

 

  • Like 1
Link to post
Share on other sites

  • RMweb Gold
2 hours ago, noiseboy72 said:

Thanks for the reply.

I did precisely that, and got it to work well enough to download the .Obj files, even if the pointless video animation didn't work. 

 

 hmm, not for me, the preview did not run as your experience, but the obj download failed with 

 

Quote

FileNotFoundError: Cannot find file: /content/pifuhd/results/pifuhd_final/recon/result_Img_256.obj

 

Link to post
Share on other sites

The following link works to remove the background from images.

 

https://www.remove.bg/

 

When retrieving the edited image select the top download option of the two  provided - its perfectly adequate and   the bottom  HD download option requires a login and credits.

Edited by monkeysarefun
  • Informative/Useful 2
Link to post
Share on other sites

I did some comparisons between photogrammetry and this single photo technique. I am sure you can predict the results...

 

This is a young American called Annie. I scanned her the other day using around 40 photos:

image.png.44436dba2b287d99cb46eda4c47ca21d.png

 

This is the 3D model of her generated with the 2D reconstruction compared to the photogrammetry model.

image.png.6c33613dbfb8002a4cdc87883d859a97.png 

At first look, the 2D conversion has done a fair job, and has brought out the facial features better than the photogrammetry, but the pose, hair and body shape are all incorrect. The detail in the jumper is knitted in, so should not really be brought out in relief. Still not a bad attempt though.

 

This is the 32mm character I've made for her from the scan.

 

image.png.09971fb236b826ef3906db46b82f38d5.png

  • Like 4
Link to post
Share on other sites

On 14/03/2023 at 13:03, RedgateModels said:

 hmm, not for me, the preview did not run as your experience, but the obj download failed with 

 

FileNotFoundError: Cannot find file: /content/pifuhd/results/pifuhd_final/recon/result_Img_256.obj

I got the same error message I'm afraid, I had assumed this might work from the demo page without going to the trouble of installing the program. Is it meant to?

 

Link to post
Share on other sites

  • RMweb Gold
1 hour ago, 5D_Stoke said:

I got the same error message I'm afraid, I had assumed this might work from the demo page without going to the trouble of installing the program. Is it meant to?

 

 

Use this link, works for me 

 

https://colab.research.google.com/drive/1gYiwvvmAhjg1nDNjN8kv6L9eOsbP-9w-?usp=sharing

  • Like 1
Link to post
Share on other sites

  • RMweb Gold
13 minutes ago, The Fatadder said:

What’s the best way to remove the background from a photo in preparation for running this?

On 14/03/2023 at 23:02, monkeysarefun said:

The following link works to remove the background from images.

 

https://www.remove.bg/

 

When retrieving the edited image select the top download option of the two  provided - its perfectly adequate and   the bottom  HD download option requires a login and credits.

 

 

  • Thanks 1
Link to post
Share on other sites

4 hours ago, RedgateModels said:

Many thanks, I've now tried that and it went through the first cell stage fine, but at the second stage, image to 3D mesh, when I thought I should be able to select a .png or .jpg file, I get the error message: 
NameError: name 'image_path' is not defined.
Sorry, I have no bank of knowledge to know what's going on! Has it not loaded the program correctly?

Link to post
Share on other sites

  • RMweb Gold
24 minutes ago, 5D_Stoke said:

Many thanks, I've now tried that and it went through the first cell stage fine, but at the second stage, image to 3D mesh, when I thought I should be able to select a .png or .jpg file, I get the error message: 
NameError: name 'image_path' is not defined.
Sorry, I have no bank of knowledge to know what's going on! Has it not loaded the program correctly?

 

Sounds like the first stage did not complete properly, or at least not well enough. No idea how to fix it mind

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...