All Things Techie With Huge, Unstructured, Intuitive Leaps
Showing posts with label software. Show all posts
Showing posts with label software. Show all posts

AI Risk Radar For Self-Driving Cars


There is a lot in the news with self-driving cars.  Google has one. Apple is building one. Mercedes already has a self-driving transport.  Even the kid (George Hotz) who carrier unlocked the iPhone and Playstation built himself a self-driving car.

You read about LIDAR systems (Wikipedia: Lidar (also written LIDAR, LiDAR or LADAR) is a remote sensing technology that measures distance by illuminating a target with a laser and analyzing the reflected light. Although thought by some to be an acronym of Light Detection And Ranging, the term lidar was actually created as a portmanteau of "light" and "radar".) and camera systems with real time video analysis, etc.

Several makes and models already partially autonomous functions like parallel parking and lane departure systems that warn you when you leave the lane. Some cars will autonomously steer on a highway when cruise control is on.  However what is missing from the whole autonomous driving vehicle is some real brains behind driving.

When a human is driving a car -- especially a human who is a good driver and taught to drive defensively -- they always have a layer of abstraction that I like to call a risk radar turned on.

The risk radar while driving is like a an analysis and environment supervisory circuit that is not directly involved in actually driving the car, but processes meta-data about driving.

For example, a risk radar would look at the outdoor temperature and if it is freezing, it would devote some cycles to see if there is black ice on the road.

A risk radar notices that in a two or more lane highway, if you are are driving in another vehicle's blind spot, you either slow down or speed up.

A risk radar notices that you are in a high deer collision area on the highway, so some extra cycles are devoted to looking for the pair of reflective phosphorescent eyes on the side of the road.

If you had to brake heavily to avoid collision, a risk radar will model the circumstance that caused that extreme corrective action and will be comparing all environmental parameters, conditions and events to watch out for similar situations.  When one or more of those risk factors are present, it goes into high alert mode.

A risk radar can actually modify the way that a vehicle is driven.  Self-driving cars will have to have sensors like an accelerometers to detect yaw and pitch due to high winds, or hydro-planing on a wet road,  Risk radar would note these things.

Risk radar would count cars and notice if the traffic was heavy.  Risk radar will notice the speed of travel of other cars and make inferences about it.

Risk radar will have a range of characteristics.  Not only will it have a library of risks and the mitigation actions associated with them, but it will also have both supervised and unsupervised machine learning.  In machine learning, supervised learning is where the machine is given the correct result so it can self-adjust weights and thresholds to learn risks and risk mitigation actions. By the same token, unsupervised learning is where the machine infers a function from input data (through various algorithms such as clustering etc).

The biggest element of risk radar for self-driving cars, is that it must be time-domain aware.  Time-domain awareness means that it must know that certain events and actions follow the arrow of time and may or may not be caused by the preceding state. This is state of cognition with time awareness is a form of artificial consciousness (see the blog entry below), and it important in implementing a high level autonomous decision as to what algorithm will be used to drive the car.  For example, if the risk radar warrants it, the car would move into a cautious driving algorithm. If the road was icy, the car would under-steer to prevent skidding.  This would require coordination between acceleration and braking that would be different from ordinary driving.

The risk radar necessary for cars would be an evolving paradigm.  Cars driving in downtown New York would have different risk points than cars self-driving in Minnesota.  Having said that, if there were a standardized paradigm for the interchange of trained neural nets, a GPS waypoint would load the appropriate neural nets into car for the geographic area that it was driving in.

The risk radar for self-driving cars is a necessity before these autonomous vehicles are seen ubiquitously on all streets.  It really is a Brave New World, and it is within our grasp.






Adventures in Speculative Software Engineering ~ How A Database Can Control Things

(click on pic for larger image)

The idea struck me as to how a regular, ordinary database can be a controller like a thermostat, or in essence any other kind of feedback control. Since this is speculative engineering, all of the components do not have to exist at this time.  This is presented in the hope that somebody gets a brainstorm from reading this, and makes something like this real.  So here goes:

You would have a sensor to start things off.  Let's suppose that it is a temperature sensor.  It would be a simple thermocouple that is made to measure temperature.  You would need an analog to digital converter so that it could be fed into a digital compute system.  Notice I didn't say computer, but compute.

Then you would need an interface to make sense of what the sensor is telling you after the Analog-to-Digital Conversion.  For that, I propose my handy-dandy XML based Universal Sensor Transfer Protocol, but instead of XML it is STML or Sensor Transfer Markup Language.  Here is what it looks like:

<?stml version="1.0" encoding="utf-8"?>
<sensor>
      <name>Caliente Temp Sensor</name>
      <serial_no>000-000-001</serial_no>
      <units>degrees</units>
      <scale>Fahrenheit</scale>
       <reading>65.9</reading>
        <timestamp>22/10/2014:20:26</timestamp>
</sensor>

Simple. So the STML package arrives at the server. The server read function reads the STML stream, converts the byte array to an object that coincides with the STML taxonomy.  This gets wordified into an NLP (Natural Language Processing) syntax that is deconstructed by a database stored procedure.  The database records the reading (temperature in this case) and a function is called to evaluate the temperature reading.  A table is read as to what the temperature should be at this time of day. and the delta is also recording.  As the delta (ideal temp minus actual temp) is poked into the database, a trigger is fired to create the appropriate response, that is fed back to the server.

The server encodes it into another control markup language that fires say the furnace or air conditioning, depending on the reading.  This control markup language is converted to machine language in an digital to analog converter and the appropriate control signal is applied to the device.

So why would have this instead of a $75 thermostat.  Firstly, if the components were developed to be off-the-shelf, you could hack an entire house to be run off a laptop with portion of it acting as a server.  You wouldn't need custom thermostats or devices, just a bunch of cheap sensors that can talk to anything.  The database will automagically record everything, and you will have your own Big Data stack where another program on your laptop/server will mine the data and extract how things should be run autonomously based on that data,

You now can look for inferences in the data between different things. For example, if you manually turn down the heat at night, or turn up the AC at night, after a few cycles, the machine learns the drill and does it for you.

A component based sensory system like this, ending up in a database has unlimited applications in making your life easier, cheaper, greener and hassle-free. I will race you to the patent office.




A Different Kind of Software -- Happiness


This is not technology related, but rather technology of the mind.  It is a different kind of state machine in the brain, and the state is happiness.  Pictures of the boreal forest make me happy. I love the great outdoors, and the wilderness, and I had to take a break from the bits and bytes to reboot my brain.  This sort of stuff also debugs my life.

Now back to regularly scheduled programming.

Giving Thanks for the Free Software

Today, I just want to give props to some free software, freely available on the web that has helped me. Yesterday I mentioned the DivX codec pack, and you can download it for free from here:


Another bit of software that has helped me tremendously is converting DVD to AVI. A small free tool is fast and quick. Here is a screen shot:


The URL for downloading this tool is:




And props also go to CoolUtils.com. I needed to convert a jpg pic to an .ico icon file for Visual Studio, and it was done promptly and easily online at:



Thanks a bunch. Readers of my other blog will know that I reciprocate, putting up code for RFID and mag card readers etc.

And this was lying on my desktop. If you need a green light pic for any development that you do, I created this one pictured below. Please take it if you need it.