Can I code an Artificial Intelligence Baby in Cycles Mode? (no real-time/interaction)


I don’t need real-time interaction.

If I use Cycles Mode, can I use Python to code my AI human baby? To for example move armatures, get numbers from ex. an accelometer for how fast it crawls and use the numbers in the code.

(SterlingRoth) #2

Potentially, though that sounds like a pretty complex project. It definitely wont be easy.

(BluePrintRandom) #3

You would be much better off using pyBullet

(SterlingRoth) #4

Frankly, I’m not convinced that the physics of an “AI baby” is the part you should be worrying about. Start with an AI sphere. Get it up and running with some basic routines (go towards the cube, go away from the cone). once you have that working, increase the complexity (have a hunger value that slowly depletes, have the cubes be food) once you get each piece complete, you will be better equipped to start the next.

Prototype it out! Build it up piece by piece, and try not to get too bogged down in the process. Having the final goal in mind is important and motivational, but you’ve still gotta pay attention to what’s right in front of you.

You have a huge project that you are trying to do. If you don’t break it down into manageable pieces, you just won’t do it.

(BluePrintRandom) #5

pyBullet has tensor flow integrated*

(SterlingRoth) #6

Oh good, that means the only thing that is standing in the OP’s way of making a living jiggling baby has been resolved.


EDIT: I’m sorry my thread question sounded like “Can I do it”. My story is I can. And I’m hiring coders because I myself cannot learn the lib/code stuff, nor convince anyone to code for me for free.

The task/amount of work is not the problem, I will make a simple yet amazing creature fast.

The only problem is if I can use code in Cycles mode. Can I? This was my opening question:

“If I use Cycles Mode, can I use Python to code my AI human baby? To for example move armatures, get numbers from ex. an accelometer for how fast it crawls and use the numbers in the code.”

Code is needed to make AI. If I can’t use code in Cycles mode, no AI lol. I don’t want to be in BGE mode.

(SterlingRoth) #8

You can append some code to an event handler to get that code to execute on frame change. This code can do pretty much anything, if you are willing to pay someone to code everything necessary. You can add system variables to store data, you can load in external libraries, you can do quite a bit. If you’ve got enough money to pay someone to code that, it is technically possible.

I programmed an astrological chart calculator based on this principle. There is permanent data loaded into blender on init, Then every frame is evaluated, objects are added/removed, materials updated, things moved around:


So I can code meh AI and have it run without being in BGE mode and stay in Cycles mode at all times(?) I’m so happy!

Yes I’ll be hiring. But you don’t mean this will cost lotsssss though do you? Like 50,000? You mean just simply hiring right? And a little work around not too bad of an additive to the job already required? For example job is “AI-blahblah” = 500USD, and to do it in Cycles mode will cost ya 200USD more. ? And will that extra cost be a one-time thing to get code working in Cycles mode? Or for each line of code?

(SterlingRoth) #10

Most coders charge by the hour, not the line.

For the scope you are talking about, you will probably need to multiply those numbers by 10 at least ($5,000-10,000). programming a human Baby AI with rigging, and soft bodies, and ‘learning’, and getting everything to run in the bpy environment is, as I’ve said, Complex. Complexity requires time, and time requires money.

You might be able to find someone super cheap to code that for you, but you often get what you pay for.

If I were to offer advice, I would recommend changing gears and going to UE4 as a platform. There are tons of coders out there intimate with AI coding, so there is a bit more competition to drive the price down. There’s maybe 10 people in the world with the capacity right now to do what you want in blender. maybe a couple hundred capable of learning it. There are thousands of capable coders out there using UE4.


I’ve already got my human baby rigged and will setup physics myself. Only coding will be left.

I tried UE4, but they want big money actually. No one on UE4 emailed me or gave offers, yet Unity and Blender did. There’s reasons I want to go with Blender - cheap, I can seriously modify my project (can’t even move things in UE4/Unity), features, faster.

Do you mean there’s 10 blender coders on Earth OR do you mean there is 10 blender coders whom know about Neural Networks/AI/Machine Learning etc? I can sorta pass CNNs/etc for a while. So, how many blender coders are there? Really want to know this.

(SterlingRoth) #12

I mean 10 coders that know enough about AI and BPY integration to be able to make that happen.

Good luck with whatever you end up going with. It’ll be tough, but it sounds like you have the endurance.

Maybe you could put some of that drive into learning some python on your own. I know there is a perception of coding as this arcane art, but it’s really not. Anyone can learn it, you just need to practice.


Hi again. I know we talked about it already, but, I didn’t really get a solid answer - I’m paying 350USD soon, and, if I can’t use code in Cycles mode after this job, I’m screwed.

@SterlingRoth When you showed me your video of that Astro Weather Animation Chart Calculator, did you EVER use BGE to create that?

I’m in Cycles mode. I’m not using BGE whatsoever. Online, people keep talking about Cycles Python for materials and nothing else (such as coding and running an intelligent baby human).

(Secrop) #14

Cycles is only a render engine. You can still use the same python logic for animation with Cycles, BI and BGE.
But I must say that progragrimng an AI baby (or an insect or even something more simple) is a great big step… A kind of step that companies like MS or Google would pay more than you would ever seen in your life time. Anyway, good luck with that… Note that it’s already difficult to make an AD baby (read Artificially Dumb). :wink:


The only thing that really worries me is not actually if Python works in Cycles mode, but actually the “call names”. Python is python. But Blender makes up “call names” (if I’m correct) so someone’s python code can call and interact with Blender. Say you python this and python that and do a calculation - ok, then you want to call/move a Blender armature bone/etc, or read a sensor reading, or anything in a video game — this requires that the call names exist. What worries me is if Cycles mode allows Python, but, doesn’t have the full list of Blender call names/keys (while BGE does) that your Python code can use, therefore rendering your Python code useless, running it, but not being able to shake hands with Blender. How do you know?

(SterlingRoth) #16

I never touch the bge. The astro weather animation was entirely scripted to run on frame change. the frame changes, the script updates and moves things around, changes materials, line thickness, whatever.

I’ll say it again, what you are asking for is very complicated and I am not convinced that running bpy code to simulate an AI is the best way to go about whatever you are trying to go about. I have a sneaking suspicion that the $350 of coding you are attempting to purchase will not result in what you are hoping.

I would strongly encourage you to slow down, do more research, and learn a little bit of coding yourself. Even if you do hire a coder to do the final work, working through to prototyping yourself will save you a ton of money long term, and also give you some more tools to debug and improve any code you do want to purchase.

(SterlingRoth) #17

Python has almost complete control over everything in blender. You can access bones, you can access materials, you can access every vertex in a mesh or every pixel of an image.

Using all that data to do what you want is very very complicated, but not impossible.


Thanks for clarification SterlingRoth.

Btw, in Cycles, when you run code, can you watch it run in the viewport without rendering? That would give me real-time.

Would you say, from your Astro Weather Animation, that you had essentially achieved player interaction, and that I could interact with my AI without resorting to BGE?

I’m choosing to go with Cycles over BGE because I heard BGE not only has less accurate Physics, but also limited Object tools like constraints, which, my project requires manipulating Blender’s tools, and as Bullet Physics goes, I better keep as accurate Physics as I can.

The 350USD I’m going to pay soon is for a technical job with the body, in Cycles, meaning if Cycles has Gotchas with its Python ability to interact with Blender, I’d probably have to redo the 350USD for the body in BGE.

I would say, if I can get coders to do each job and get payed, it will be pretty amazing fast in only a few jobs, and the tweaking to add on jobs would be done in each job.

(SterlingRoth) #19

For my animation, I had it set up so that you would first run the script and it would calculate what was going on for each frame, then record that information internally. then, the section of code that ran between frames would access that stored information and update the geometry.

There is no interaction, you set the code up, then the code executes and generates data for each frame. Theoretically, you could add some degree of interaction to your per-frame code, but it would be extremely complicated.

doing it this way also imposes some limits on how long your simulation can be. if you want to have a persistent baby doing, whatever it is you are trying to get the baby to do… you’re probably only going to be able to do it ~1000 frames at a time.

if you want long term simulation and interaction, you’ll need to look for a different solution.


Why is it limited to ~1000 frames? My code runs itself without me having to keyframe anything…

Are you saying half of the code runs before any rendering? Would that have the same result i.e. getting reward for acceleration and choosing best action set with highest rank? Or having the cameras in its eye sockets take the right pictures as if it was crawling…?