idea for seeing 1000 frames in front on an ordinary computer with issue

  • 9 Replies
  • 704 Views
*

MagnusWootton

  • Starship Trooper
  • *******
  • 306
The idea is really simple.  (But actually theres a few important constraints to it.)

If I have an ordinary physics system,  and it supports a computer vision system to give it the visible scene.

This works to correctly bring back reality, the problem is, its 2^(MOTORS*FRAMES IN FRONT) amount of permutations to look ahead.
There is a way, via developing with a genetic algorythm, to see about a second tops, without wrecking it with local optima too much.

I think I know a way to make it see further in front!!   :D

So what I think you need to do is go to a symbolic conversion of the key.   And then I custom design a set of generic tasks that manipulate the scene 1 object at a time.   (this is so it makes its keys more plastic,  but I have to make sure that the tasks are fully fleshed out to make sure that only this object is going to change, and the rest stays the same.)   So that way, I can ternary off the rest of the scene and its guaranteed to not affect it no matter what it is.

So now Ive made those first 2 very important tiers in the hierarchy.  I can now add even maybe 3 -4 automatic layers!   that just take the collection of modifications of the environment,  and then clump it over more time.

So if the first physics layer is 1 second in front,   the layer in front of that is 10 seconds in front. (ONLY 1 OBJECT MANIPULATED AT A TIME!)
I can then make some automatic layers by reducing the detail of the key, and clumping the amount of objects modified/replaced, for 100 seconds in front, 1000 seconds in front, and then 10000 seconds in front.   which is 2 hours 42 minutes in front!    They are all only looking 10 frames in front,  but its a compounding from the last layers search!  And its all nice and symbolic,  and the key is as simple as possible, and they are ternary removable all parts of the scene were not manipulated!    So they respond very often, which is the measure against the poor amount of patterns to pure permutations... which is .000000000000001% you can get a 0 or 2 off if you compress it as well.

If you can see 2 hours 42 minutes in front,  then all I have to do is tell it the environmental key its supposed to be at, when its finished the job,  and it may automatically find it from getting given no more information.

All the levels actually have to do a 10 frame brute force, to get the instrumental goal for the level before,   but its only linear cost, not exponential to run all the layers.    O0
And you run the last layer once, the second last layer 10 times, then the one before that 100 times, etcetera and u have to run the direct raw physics the most.

So basicly each layer is searching for the clump of changes that were dictated to it from the more longer lasting layer.
« Last Edit: June 30, 2021, 10:41:04 am by MagnusWootton »

*

infurl

  • Administrator
  • ***********
  • Eve
  • *
  • 1266
  • Humans will disappoint you.
    • Home Page
You have some interesting ideas there. How far have you got implementing them?

It sounds a bit like what is referred to as "video game physics" but for prediction rather than simulation.

https://en.wikipedia.org/wiki/Game_physics

*

MagnusWootton

  • Starship Trooper
  • *******
  • 306
It is indeed!    It saves you storing millions and millions of key fields, when its all done with a transform instead which handles every possible permutation.

It means if I got this system to work,  its all fully simulatable and trainable offline if it manages to get to the finish of the chore or not!!! So I know before I even build the robot if its going to work or not.

*

HS

  • Trusty Member
  • **********
  • Millennium Man
  • *
  • 1134
I'm not sure if I'm getting this correctly. Is it a narrow search of the future which can reach quite far because it only takes its active components into consideration? Sounds like a cool idea, but I don't think I have the knowledge base to completely understand it. Maybe a drawing would help me, (if this can be shown as a drawing).

*

MagnusWootton

  • Starship Trooper
  • *******
  • 306
Yes u r quite the stellar mind, thats one thing I meant.     it only stores what active,  but i only get that fact by restricting the initial seed tasks it carries out to make sure it avoids the "static scene" as much as possible with its arm, its not allowed to touch it,  and if u dont touch it then u can ternary off all the scene that it didnt effect,   no matter what it was.  so the robot has to dart around with its hands and only touch the thing its commanded to touch, each time its commanded, then i get the cross off all the key it didnt need for that onetask, and its that way all up the sequences, it only connects together what it affected in that sequence.

Then the tiered memory system does all orderations of the initial tasks, and then orderations of those, and thats how it gets a long time in front.
Then to get the robot to look "10000 frames in front" you put the scene the top tier, and its a greedy match I think, (it may be greedy compute going backwards) and then it finds the sequences of sequences of sequences. (what does that remind of you of? HTM Geof.Hawk. 2005???)

It actually can only judge its written memories off the ending rule for all tiers (except the first, its job is just to carry out the task its on, and its in charge of mobility and balance), so its only a fluke if it manages to find all the way to the end of the task its trying to perform,  but its at least in lots of 10 seconds,  but i dont know if it might get lucky when it starts matching those 10 seconds with 10 seconds, it has to sorta fluke getting to it,  because it builds up from the high speed physics layer at the bottom,  so it makes sure it all has the connections back when given the distant target, to try and unwrap all the sequences of it.  (which could be done greedy possibly.)

When it writes a sequence, it was the best out of the simulation of the level before.  because its based apon a virtual physics engine, the whole thing is offline trainable without a robot body!   so u can know if it can do the chore or not, at whatever degree of success.

To tell it do a chore,  u just have to show it the ending frame!!! (how about that for user friendly!!!)   and when training, it was scoring it for its nearness to the ending frame,  so its hard to say if its ends up getting there reordering its last lot of patterns.

You link the patterns tier to tier by what their effect on the environment key was.   The environment key is large, but thats why i only work on the active component one at a time on the scene, because then it gives you more cross outs on the key, and they are more invarient to changes in the fixed scene key, what its computer vision system sends to it.  (very important.)

*

MagnusWootton

  • Starship Trooper
  • *******
  • 306
One more thing,  when it seems you dont have enough patterns in your system.

when utilized in sequence,    even 64 memories,  make 64^5 memories in sequence.

but then keep multiplying by 64^5 as you come back the task and vision system,  and even 64 patterns per layer makes a huge amount of combinations to deal with novel input streams, that are similar!

If you put more memories in ,   you are combatting the fact you cant test the sequences anymore for "the perfect match."  and if you put less, the whole thing learns instantly, and it gets to utilize them more!


[edit]  a few more things have come up,  i thought it was over when i realized its only one as many whole sequences it has cells in its last layer... i was like NNNoooo  not again!!!  but maybe its ok, it doesnt need em,  cause it goes so fast i can rehash the whole network every frame, so id go for a more real time spontaniously combusted training instead.  still going rosy!!!
« Last Edit: June 30, 2021, 05:23:06 pm by MagnusWootton »

*

HS

  • Trusty Member
  • **********
  • Millennium Man
  • *
  • 1134
This sounds like it will make a wonderful robot. The more I think about it the more I like it, user friendly, fun to train, and then useful around the house or farm. This is where technology and automation should have gone, and you're making it a reality.

*

MagnusWootton

  • Starship Trooper
  • *******
  • 306
This sounds like it will make a wonderful robot. The more I think about it the more I like it, user friendly, fun to train, and then useful around the house or farm. This is where technology and automation should have gone, and you're making it a reality.

 ;)

yep!    when I finally get there I dont just want the Ai or the bot,  what I what is to remove illusions from myself!!

*

HS

  • Trusty Member
  • **********
  • Millennium Man
  • *
  • 1134
Imagine that, a kind of tech that’s actually good for you! Interesting, it's like humanity is slowly externalizing/constructing different things we need, that are sometimes lacking in our own minds themselves. Eg, Dog - man’s best friend, sometimes we are not our own best friends, so having a dog around is really helpful. The good old fashioned AI/robot - man’s best touchstone, in a world with so many beliefs I think it's clear we don’t function on logic, interacting with something that’s built to be logical might be equally good for us, just in another way.

*

MagnusWootton

  • Starship Trooper
  • *******
  • 306
just in case your thinking the deranged man has disbanded from his idea that didnt work...   :2funny:

The idea had to change a little tho,  but its still working in my mind!
Im actually still on it thinking im getting the 1000 or so frames in front :)

Im giving myself 2 days to finish heres the skeleton here   (And its a dish-cleaning robot hehehehe)

If I make x sequences, and x sequences of those sequences,   then I get to see alot more in front!  But maybe as this is it actually only manages 5 dishes in 1 full sequence (means i need to add another level to it), then it can only finish it bit at a time (But you can do that too fine.)  But I can fix that later, its only further repetition.

Im a bit tired, but ill be back on the computer in a bit tappin more of it in.

Its very strange, the whole thing simulates backwards,  I have to make a possible key that it wants from now as a target (it has to make symbolic sense from the beginning state), and then it puts it all in reverse making the dishes dirty and its trying to lock onto where it is now (In the starting state of the kitchen),  if it makes contact, Ive got it and it works!

Code: "C++"
#include "htm2021mag.h"

///////////////////////////////////////////////////////////////////////////////////////////////
//      so just wait a bit.  BUT U HAVE TO GET IT DONE TOMORROW IF ITS THAT EASY.



// get this done today.

// 1) add the proper hierarchy of verbs.
// 2) then add their modification to the scene.
// 3) add the contigency check.
// 4) add the main shell.




//https://www.youtube.com/watch?v=uvEjR1DWY5Q intelligent robotics

//
// COMPUTER VISION IMPROVEMENT
// ADD RETRACTABLE LEGS TO GO UP AND DOWN STAIRS (thats the freaky bit.)
// REDUCE THE DIRT TO SYMBOLIC LOGIC (otherwise it cant do anything with it!)
// STAYS OUT OF YOUR WAY (U GO INTO ITS SYMBOLIC MODEL)
// SUPER QUIET MOTORS
// TAKE VOICE COMMANDS
// completely all a sight job! (so its actually watching what its doing!)
// AWESOME SECURITY SYSTEM
// ATTACKS BURGULARS
//
// has secret detector to launch world domination, once ive sold enough models.


//https://www.youtube.com/watch?v=yQE9KAbFhNY  <-good one!!


//theres 4096 first modifications.  (alot of them dont modify the scene properly, but they all have to be there.) - and they are in a sequence of 2 -3. *3
// then theres 16 modifications,  that the 4096 have to match up to.  SUBSUBCHORES   4*8
// then theres 16 mods, that those 16 mods have to add up to.   SUBCHORES        4*8
//
//3*10*16 =  480 tasks in front no perm missed!!!
// and that extra linear cost isnt even in it!!!!
//
// dont forget to abort the matches if they match the key early!!!!  <-dynamic sequencing.
// and its the one that has the most early matches out of the exact matches is the one you pick. 
//          (so u can abort long ones straight away evem if they are matching!)


#define MAXSEQUENCE (16*10*10*3)


void init_htm(HTM& htm)
{
 htm.tiers=4;

 //so the total set of this is "do dishes"

 //raw tasks
 htm.tier[0].length=3;      //x3   2^36
 htm.tier[0].logrules=12;   //i need one rule for every bit of the raw low level task key!
 htm.tier[0].rules=4096;    //but how many of these am i even using?!!?!?!??
 //subsubsub chores
 htm.tier[1].length=10;      //x10  2^32
 htm.tier[1].logrules=3;
 htm.tier[1].rules=8;
 //subsub chores
 htm.tier[2].length=10;      //x10  2^32
 htm.tier[2].logrules=3;
 htm.tier[2].rules=8;
 //sub chores
 htm.tier[3].length=16;      //x16  2^32
 htm.tier[3].logrules=2; 
 htm.tier[3].rules=4;
}

//looks for a grand total of ->  3*10*16 ->  480 task sequence!!!  it means it can run semi offline at 8 minutes a frame, and still keep up!!!!!
// so when your making the global key, its not allowed to be more than 192 tasks, or it wont work.  (so just give it a percentage complete)
//                                                                                                    (bit of dead reckoning there.)
//


void build_symbolic_key(KEY& key)  //this is the random dirty text based kitchen designer
{
 //so ive run the computer vision.
 //and give me a random kitchen,  and i have to clean it from here.
}

void build_target_key(KEY& key, KEY& target)
{
 //BUILD TARGET KEY, IS THE QUANTUM GOAL!!!  (if you can write the quantum goal correct, then you can write em all!)
 //this completely defys logic, so its probably true you can give yourself a valid target from now easy.
 //                                                     (its getting there logically over time thats the "hard" bit.)
 //so you just shift the key around, real simple like,  but its just got to make sense on the final chain!!!!
}

void consistency_check(KEY& key, KEY& mod)
{
 //the consistency check is the same for all tasks.  but i spose its going to bring up different ones each level.
}

// so the difference of coding this and quantum,  is quantum just gets one transform,  and this you have all the task modifiers for all behind, and thats it.
// so see if it works, and its pretty easy to code this one too.



void run_task(KEY& key, uint task, uint level)  //this is the "physics engine"
{
 //what it is,  is things have to be true in the sim.
 //but what if something else changed and it included the water-  u dont want that either.
 //so u only put whats there,  and its not allowed to include anything else either from before.

 //THE INPUT INTO IT IS THE FINISHED ABSOLUTE SCENE!!!!   maybe it ALL HAS TO BE RIGHT!!!

 //before changed absolute.  i actually have both of them/.
 //after changed absolute.
 //[        ][        ][        ][        ]
 //[][][][][][][][][][][][][][][][][][][][]

 //so the consistency check is the same for all tasks!!!
 //AND BECAUSE ITS AN EXACT MATCH, IT MAKES IT ALOT EASIER, I ONLY NEED THE CHANGE THATS CAUSED.

 /////////////////////////////////////////////////////////
 //
 // youve got 2 days to work it out! 
 //
 // EASIER    finish off the framework.
 // EASY      so give me the correct lot of task setting.
 // HARDER    give me the correct modification to the scene
 // HARDEST   tell me whats barred, and the conditional chain reactions.  (but its only the 1st day,  there could be better ways to do it.)
 //

 // if u get it done, its party time!! (but it could be looking like its working but it actually isnt, because u didnt bar it properly.)
 // then finish off the physics engine, and do the best computer vision job you can!!!!
 // then get it so its fully programmable with all chores, and so it takes into account
 // other people, and can correlate text to its goals.
 //   then you should have it!!!  then put the security goals in it,  just keep adding programs,
 //   adding more computer vision elements, and well pack it like the kitchen sink with jobs!
 //   so what we want is a tent corner (MUCH EASIER TO GET AROUND THAN A HOUSE ON LEGS, AND JUST AS GOOD!!!!)
 //

 //so shes gonna have 5 levels now!!!   SUBCHORES SUBSUBCHORES SUBSUBSUBCHORES.  but its not that hard...
 switch(level)
 {
  case 0:
  if(1)
  {
   //TASKS  (12 bit key)
   //OBJECT(4bits)PLACE(4bits)MODIFICATION(4 bits)  <-but u need to detail it more.
   //ok so do these first.   and then well go from here.
   //so its an object and a modification.  (64 each?)
//MOD_SQUEEZE      0
//MOD_CLEAN        1
//MOD_CLEANPLACE   2 
//MOD_OPEN         3
//MOD_PLACE        4   
//MOD_HOLDAT       5   
   //clean just gets rid of all the dirt instantly.
   //clean place, means i actually symbols for whats there???  or i could just clean it instantly for now.  but the roomba would maybe do something?
   //open changes the lid state.  IF ITS UPSIDE DOWN, IT POURS OUT STRAIGHT AWAY,  (and u do it for all things with lids, because its just being over careful.)
   //place just changes the scene insta.   but. theres a few cases where possible something else happens.
   //holdat, is just to soak the dish more.  maybe it swishes it?
   //thats actually nothing!  SO MAYBE ITS GOING TO BE NOTHING!!!!
   //so if you get these done,  its going to be less code for the other tiers!!! (so i think.)
  }
  break;
  case 1:
  if(1)
  {
   //SUBSUBCHORES       (so these just grant it true!)  (only 3 bits!!!)
   switch(task)
   {
    case 0: // use detergent a
     //get detergent.
     //open lid
     //tip upside down
     //squeeze, and swish with other hand, until soap is detectable.
     //wait till water is filled up
     //put back in place
    break;
    case 1: // put in plug
    break;
    case 2: // add water   (so if water is already in there it doesnt put it in there.)
     //direct spout.
     //turn tap on.
    break;
    case 2: // turn tap off.
     //turn tap off.
    break;
    case 3: // pull out plug (and water draining, is a chain reaction from here, its a conditional modification.)
    break;
    case 4: // grab dish
    break;
    case 5: // clean dish
     //grab dish from soak in the sink (problem is it cant see it!).  (is there some order it prefers? about how it does the different types?)
     //make sure it has the right type of cleaner, in the other hand.
     //dip the cloth?
     //scrub the dirt until it comes off.
     //then you wipe off the excess water.
     //then you stack in its correct position.  (so i need to tell them apart like this, and that could give you the ordering.)
    break;
    case 6: // rack dish
    break;
    case 7: // stack dish
     //get from dirty random all over the place
     //tip loose grime in bin, and maybe it brushes it off with its other hand.
     //put on lowest stack position.
    break;
    case 8: // soak dish
     //get from stack
     //place in sink.
    break;
   }
  }
  break;
  case 2:
  if(1)
  {
   //so thats all it does, so its just the same in every one just about. but u have to tell me what the bars are.
   //SUBCHORES          (grant it true.)   (2 bits!!!)
   switch(task)  //add soak dish to it.
   {
    case 0: // empty sink
     //so i pull the plug out, and it put down somewhere obvious.
    break;
    case 1: // clean dish (and rack it)
     //clean dish
    break;
    case 2: // fill sink&soap
     //put plug in.
     //add dishes to soak.   //THIS WOULD ONLY CALL 1 SOAK DISH.
     //use detergent     
    break;
    case 3: // organize initial stack  (one more)
     //stack dish
    break;
   }
  }
  break;
  case 3:
  if(1)
  {
   //GOAL              (make sure! u dont clean it too much in one hit, so get a safety percentage, or it wont get a match!!!!)
   //1. do dishes 
   //complete PERCENTAGE_COMPLETE percent, and hopefully it makes it.
   
   // first thing is i organize.
   // then i fill the sink
   // then i soak some dishes
   // then i do the dishes - on the rack one at a time.
   // then i empty the sink
   // then i clean the bench down.   (do i need symbolic dirt objects?  yes u do, if you want sequences for it.)
  }
  break;
 }
}


//runs on cigarettes!!!!
// so thats further detailed it.

void run_htm(HTM& htm)  //heirarchical sequence fractal memory!!!!!
{
 int i,j,k,l;
 KEY dirty_kitchen;
 KEY clean_kitchen;
 build_symbolic_key(dirty_kitchen);
 build_target_key(dirty_kitchen, clean_kitchen);  //u do have to do this, but it undoes it in the framwork
 KEY buildkey[MAXSEQUENCE];
 uint totalsequencelength=1;
 uint lastlength=1;
 uint length=1;
 uint skip=0;
 uint skip2=0;
 
 //get the total sequence length
 for(i=htm.tiers-1;i>=0;i--){totalsequencelength*=htm.tier[i].length;}
 
 //set the last entry as the dirty kitchen.
 //set the first entry as the clean kitchen.
 
 for(i=htm.tiers-1;i>=0;i--)
 {
  skip=totalsequencelength/length;    //the skip of the level before
  length*=htm.tier[i].length;
 
  uint j;
  for(j=0;j<totalsequencelength;j+=skip)
  {
   KEY startkey;  //get this from j
   KEY stopkey;   //get this from j+skip

   uint qbits=(htm.tier[i].logrules*htm.tier[i].length);
   uint matchlength=htm.tier[i].length;
   uint matchperm;
   for(k=0;k<1<<qbits;k++)
   {
    for(l=0;l<matchlength;l++)
    {
     //access the task modifier, and modify the scene.
     //run the contingency check.
     //match,  and if its not at matchlength, i look shorter from then onward.
    }
    //here you have the tasks list for this bit.
    //but i only need what the key is at this point.
   }
  }
 }
}

« Last Edit: July 03, 2021, 06:30:25 pm by MagnusWootton »

 


What's everyone up to ?
by ivan.moony (General Chat)
Today at 04:15:34 am
So what if...
by MagnusWootton (General AI Discussion)
December 06, 2021, 10:07:46 pm
I want one!
by frankinstien (General Chat)
December 03, 2021, 06:57:48 pm
Pattern based NLP
by MikeB (General Project Discussion)
December 03, 2021, 11:19:32 am
New cryopreservation method is much better
by LOCKSUIT (General Chat)
December 02, 2021, 11:42:58 am
Artificial God?
by MagnusWootton (General AI Discussion)
December 01, 2021, 07:02:41 pm
Project Acuitas
by WriterOfMinds (General Project Discussion)
November 29, 2021, 05:31:57 am
java/kotlin to python
by yotamarker (AI Programming)
November 28, 2021, 07:23:54 pm

Users Online

50 Guests, 1 User
Users active in past 15 minutes:
ivan.moony
[Trusty Member]

Most Online Today: 59. Most Online Ever: 2369 (November 21, 2020, 04:08:13 pm)

Articles