mouthporn.net
#artificial intelligence – @h4x0r3d on Tumblr
Avatar

through h4x0r3d's eyes

@h4x0r3d / h4x0r3d.tumblr.com

+-------------------------------+ .:[h4x0r3d@Hackerzlair]:. +-------------------------------+ .:[Links]:. > KOPIMI > HACKER EMBLEM > DATALOVE! > CASCADIA > ABOUT.ME #CYBERWHALEWARRIOR #DGR +-------------------------------+
+-------------------------------+
Avatar

The incredible inventions of #intuitive #AI | Maurice Conti ~ Almost. There.

“ What do you get when you give a design tool a digital nervous system? Computers that improve our ability to think and imagine, and robotic systems that come up with (and build) radical new designs for bridges, cars, drones and much more -- all by themselves. Take a tour of the Augmented Age with futurist Maurice Conti and preview a time when robots and humans will work side-by-side to accomplish things neither could do alone. “

Avatar

OpenAI Gym is a toolkit for developing and comparing reinforcement learning algorithms. It makes no assumptions about the structure of your agent, and is compatible with any numerical computation library, such as TensorFlow or Theano. You can use it from Python code, and soon from other languages.

OpenAI Gym consists of two parts:

  1. The gym open-source library: a collection of test problems — environments — that you can use to work out your reinforcement learning algorithms. These environments have a shared interface, allowing you to write general algorithms.
  2. The OpenAI Gym service: a site and API allowing people to meaningfully compare performance of their trained agents.

Getting started

To get started, you'll need to have Python 2.7 or Python 3.5. Fetch the gym code using:

git clone https://github.com/openai/gym cd gym pip install -e . # minimal install

You can later run pip install -e .[all] to do a full install (this requires cmake and a recent pipversion).

pip install gym and pip install gym[all] will also work if you prefer to fetch gym as a package.

Running an environment

Here's a bare minimum example of getting something running. This will run an instance of the CartPole-v0 environment for 1000 timesteps, rendering the environment at each step. You should see a window pop up rendering the classic cart-pole problem:

import gym env = gym.make('CartPole-v0') env.reset() for _ in xrange(1000):    env.render()    env.step(env.action_space.sample()) # take a random action

It should look something like this:

Normally, we'll end the simulation before the cart-pole is allowed to go off-screen. More on that later.

If you'd like to see some other environments in action, try replacing CartPole-v0 above with something like MountainCar-v0, MsPacman-v0 (requires the Atari dependency), or Hopper-v1 (requires the MuJoCodependencies). Environments all descend from the Env base class.

Note that if you're missing any dependencies, you should get a helpful error message telling you what you're missing. (Let us know if a dependency gives you trouble without a clear instruction to fix it.) Installinga missing dependency is generally pretty simple. You'll also need a MuJoCo license for Hopper-v1.

Observations

If we ever want to do better than take random actions at each step, it'd probably be good to actually know what our actions are doing to the environment.

The environment's step function returns exactly what we need. In fact, step returns four values. These are:

  • observation (object): an environment-specific object representing your observation of the environment. For example, pixel data from a camera, joint angles and joint velocities of a robot, or the board state in a board game.
  • reward (float): amount of reward achieved by the previous action. The scale varies between environments, but the goal is always to increase your total reward.
  • done (boolean): whether it's time to reset the environment again. Most (but not all) tasks are divided up into well-defined episodes, and done being True indicates the episode has terminated. (For example, perhaps the pole tipped too far, or you lost your last life.)
  • info (dict): diagnostic information useful for debugging. It can sometimes be useful for learning (for example, it might contain the raw probabilities behind the environment's last state change). However, official evaluations of your agent are not allowed to use this for learning.

This is just an implementation of the classic "agent-environment loop". Each timestep, the agent chooses an action, and the environment returns an observation and a reward.

The process gets started by calling reset, which returns an initial observation. So a more proper way of writing the previous code would be to respect the done flag:

import gym env = gym.make('CartPole-v0') for i_episode in xrange(20):    observation = env.reset()    for t in xrange(100):        env.render()        print observation        action = env.action_space.sample()        observation, reward, done, info = env.step(action)        if done:            print "Episode finished after {} timesteps".format(t+1)            break

This should give a video and output like the following. You should be able to see where the resets happen.

[-0.061586   -0.75893141  0.05793238  1.15547541] [-0.07676463 -0.95475889  0.08104189  1.46574644] [-0.0958598  -1.15077434  0.11035682  1.78260485] [-0.11887529 -0.95705275  0.14600892  1.5261692 ] [-0.13801635 -0.7639636   0.1765323   1.28239155] [-0.15329562 -0.57147373  0.20218013  1.04977545] Episode finished after 14 timesteps [-0.02786724  0.00361763 -0.03938967 -0.01611184] [-0.02779488 -0.19091794 -0.03971191  0.26388759] [-0.03161324  0.00474768 -0.03443415 -0.04105167]

Spaces

In the examples above, we've been sampling random actions from the environment's action space. But what actually are those actions? Every environment comes with first-class Space objects that describe the valid actions and observations:

import gym env = gym.make('CartPole-v0') print env.action_space #> Discrete(2) print env.observation_space #> Box(4,)

The Discrete space allows a fixed range of non-negative numbers, so in this case valid actions are either 0 or 1. The Box space represents an n-dimensional box, so valid observations will be an array of 4 numbers. We can also check the Box's bounds:

print env.observation_space.high #> array([ 2.4       ,         inf,  0.20943951,         inf]) print env.observation_space.low #> array([-2.4       ,        -inf, -0.20943951,        -inf])

This introspection can be helpful to write generic code that works for many different environments. Boxand Discrete are the most common Spaces. You can sample from a Space or check that something belongs to it:

from gym import spaces space = spaces.Discrete(8) # Set with 8 elements {0, 1, 2, ..., 7} x = space.sample() assert space.contains(x) assert space.n == 8

For CartPole-v0 one of the actions applies force to the left, and one of them applies force to the right. (Can you figure out which is which?)

Fortunately, the better your learning algorithm, the less you'll have to try to interpret these numbers yourself.

Environments

gym's main purpose is to provide a large collection of environments that expose a common interface and are versioned to allow for comparisons. You can find a listing of them as follows:

from gym import envs print envs.registry.all() #> [EnvSpec(DoubleDunk-v0), EnvSpec(InvertedDoublePendulum-v0), EnvSpec(BeamRider-v0), EnvSpec(Phoenix-ram-v0), EnvSpec(Asterix-v0), EnvSpec(TimePilot-v0), EnvSpec(Alien-v0), EnvSpec(Robotank-ram-v0), EnvSpec(CartPole-v0), EnvSpec(Berzerk-v0), EnvSpec(Berzerk-ram-v0), EnvSpec(Gopher-ram-v0), ...

This will give you a list of EnvSpecs. These define parameters for a particular task, including the number of trials to run and the maximum number of steps. For example, EnvSpec(Hopper-v1) defines an environment where the goal is to get a 2D simulated robot to hop; EnvSpec(Go9x9-v0) defines a Go game on a 9x9 board.

These environment IDs are treated as opaque strings. In order to ensure valid comparisons for the future, environments will never be changed in a fashion that affects performance, only replaced by newer versions. We currently suffix each environment with a v0 so that future replacements can naturally be called v1, v2, etc.

It's very easy to add your own enviromments to the registry (and thus be creatable by make). Justregister them at load time. (If you implement your own environments, please let us know! We're accepting pull requests for new environments.)

Recording and uploading results

Gym makes it simple to record your algorithm's performance on an environment, as well as to take videos of your algorithm's learning. Just use your environment's monitor as follows:

import gym env = gym.make('CartPole-v0') env.monitor.start('/tmp/cartpole-experiment-1') for i_episode in xrange(20):    observation = env.reset()    for t in xrange(100):        env.render()        print observation        action = env.action_space.sample()        observation, reward, done, info = env.step(action)        if done:            print "Episode finished after {} timesteps".format(t+1)            break env.monitor.close()

This will log your algorithm's performance to the provided directory. The monitor is fairly sophisticated, and supports multiple instances of an environment writing to a single directory.

You can then upload your results to OpenAI Gym:

import gym gym.upload('/tmp/cartpole-experiment-1', api_key='YOUR_API_KEY')

The output should look like the following:

[2016-04-22 23:16:03,123] Uploading 20 episodes of training data [2016-04-22 23:16:04,194] Uploading videos of 2 training episodes (6306 bytes) [2016-04-22 23:16:04,437] Creating evaluation object on the server with learning curve and training video [2016-04-22 23:16:04,677] **************************************************** You successfully uploaded your agent evaluation to OpenAI Gym! You can find it at:    https://gym.openai.com/evaluations/eval_tmX7tssiRVtYzZk0PlWhKA ****************************************************

Evaluations

Each upload results in an evaluation object on our servers. You should then create a Gist showing how to reproduce your result. Your evaluation page will have a box like the following into which you can past your Gist's URL:

...

Gist URL  

Alternatively, you can provide your Gist at upload time by passing a writeup parameter:

import gym gym.upload('/tmp/cartpole-experiment-1', writeup='https://gist.github.com/gdb/b6365e79be6052e7531e7ba6ea8caf23', api_key='YOUR_API_KEY')

Your evaluation will be automatically scored, and have a nice page that you can show off to others.

On most environments, your goal is to minimize the number of steps required to achieve a threshold level of performance. (The threshold is defined per environment.) On some environments (especially very difficult ones), it's not yet clear what that threshold should be. There, your goal is instead to maximize final performance.

Reviewed evaluations

(This process will be a work-in-progress for the foreseeable future. The more usage we see, the more we can arrive at something great!)

For each environment, we maintain a list of reviewed evaluations. This is inspired by the mechanics of peer review: we want to make OpenAI Gym ideal for research and collaboration, rather than make it into a leaderboard-based competition. (Currently only OpenAI team members have the ability to curate this list, but out of necessity rather than desire — we'd love to have community moderators once we've gotten our bearings.)

The reviewed list is intended to contain solutions which made a new contribution to OpenAI Gym at the time of creation. At least for now, we require all results to be reproduced by the community. (That way, over time we'll have an open library of correct results and reusable implementations!) New contributions include:

  • Coming up with a new algorithm that works much better than anything else.
  • Modifying someone else's solution to get meaningfully better performance than they did.
  • Implementing an algorithm from the literature not yet on the reviewed list.

It's not just about maximizing score; it's about finding solutions which will generalize well. Solutions which involve task-specific hardcoding or otherwise don't reveal interesting characteristics of learning algorithms are unlikely to pass review.

How to get reviewed

First, keep in mind that all solutions must be reproduced before passing review. So your Gist writeup should make it very easy for others to reproduce your results, or else it's unlikely anyone will go through the effort. Everyone reproducing solutions is a volunteer, so it's always your responsibility to get people excited to do so.

It's probably a good starting point to try to get another community member (friends and coworkers are fine) to reproduce your solution. You can also ask in chat.

How to help

There's a lot you can do to help!

  • Solve environments and submit your evaluations!
  • Reproduce others' solutions, and let the solution author (constructively) know how it goes by commenting on their Gist. Depending on demand, we'll release tools to help you find solutions to reproduce. Until then you can hang around in chat.
  • Integrate new environments into gym. Please show that you have run several well-implemented RL algorithms on it, and you have good reason to believe that it is tractable but not too easy. (If there's demand, we may introduce a registry for sharing environment collections without pulling them into the main repository.)
Avatar

#DropTheDrone Each weekday, dozens of U.S. government aircraft take to the skies and slowly circle over American cities. Piloted by agents of the FBI and the Department of Homeland Security (DHS), the planes are fitted with high-resolution video cameras, often working with “augmented reality” software that can superimpose onto the video images everything from street and business names to the owners of individual homes. At least a few planes have carried devices that can track the cell phones of people below. Most of the aircraft are small, flying a mile or so above ground, and many use exhaust mufflers to mute their engines — making them hard to detect by the people they’re spying on.The government’s airborne surveillance has received little public scrutiny — until now. BuzzFeed News has assembled an unprecedented picture of the operation’s scale and sweep by analyzing aircraft location data collected by the flight-tracking website Flightradar24 from mid-August to the end of December last year, identifying about 200 federal aircraft. Day after day, dozens of these planes circled above cities across the nation. Click The Title For The Full Story! ^

Avatar

Fully Autonomous Weapons Would Increase Danger to Civilians

November 19, 2012

  • The United Kingdom’s Taranis combat aircraft, whose prototype was unveiled in 2010, is designed strike distant targets, “even in another continent.” While the Ministry of Defence has stated that humans will remain in the loop, the Taranis exemplifies the move toward increased autonomy.
  • © 2010 AP Photo
  • © 2012 Russell Christian for Human Rights Watch
  • The South Korean SGR-1 sentry robot, a precursor to a fully autonomous weapon, can detect people in the Demilitarized Zone and, if a human grants the command, fire its weapons. The robot is shown here during a test with a surrendering enemy soldier.
  • © 2007 Getty Images

Related Materials: 

Giving machines the power to decide who lives and dies on the battlefield would take technology too far. Human control of robotic warfare is essential to minimizing civilian deaths and injuries.  

Steve Goose, arms director

(Washington, DC) – Governments should pre-emptively ban fully autonomous weapons because of the danger they pose to civilians in armed conflict, Human Rights Watch said in a report released today. These future weapons, sometimes called “killer robots,” would be able to choose and fire on targets without human intervention.  The 50-page report, “Losing Humanity: The Case Against Killer Robots,” outlines concerns about these fully autonomous weapons, which would inherently lack human qualities that provide legal and non-legal checks on the killing of civilians. In addition, the obstacles to holding anyone accountable for harm caused by the weapons would weaken the law’s power to deter future violations. “Giving machines the power to decide who lives and dies on the battlefield would take technology too far,” said Steve Goose, Arms Division director at Human Rights Watch. “Human control of robotic warfare is essential to minimizing civilian deaths and injuries.” “Losing Humanity is the first major publication about fully autonomous weapons by a nongovernmental organization and is based on extensive research into the law, technology, and ethics of these proposed weapons. It is jointly published by Human Rights Watch and the Harvard Law School International Human Rights Clinic. Human Rights Watch and the International Human Rights Clinic called for an international treaty that would absolutely prohibit the development, production, and use of fully autonomous weapons. They also called on individual nations to pass laws and adopt policies as important measures to prevent development, production, and use of such weapons at the domestic level. Fully autonomous weapons do not yet exist, and major powers, including the United States, have not made a decision to deploy them. But high-tech militaries are developing or have already deployed precursors that illustrate the push toward greater autonomy for machines on the battlefield. The United States is a leader in this technological development. Several other countries – including China, Germany, Israel, South Korea, Russia, and the United Kingdom – have also been involved. Many experts predict that full autonomy for weapons could be achieved in 20 to 30 years, and some think even sooner.

“It is essential to stop the development of killer robots before they show up in national arsenals,” Goose said. “As countries become more invested in this technology, it will become harder to persuade them to give it up.” Fully autonomous weapons could not meet the requirements of international humanitarian law, Human Rights Watch and the Harvard clinic said. They would be unable to distinguish adequately between soldiers and civilians on the battlefield or apply the human judgment necessary to evaluate the proportionality of an attack – whether civilian harm outweighs military advantage. These robots would also undermine non-legal checks on the killing of civilians. Fully autonomous weapons could not show human compassion for their victims, and autocrats could abuse them by directing them against their own people. While replacing human troops with machines could save military lives, it could also make going to war easier, which would shift the burden of armed conflict onto civilians. Finally, the use of fully autonomous weapons would create an accountability gap. Trying to hold the commander, programmer, or manufacturer legally responsible for a robot’s actions presents significant challenges. The lack of accountability would undercut the ability to deter violations of international law and to provide victims meaningful retributive justice. While most militaries maintain that for the immediate future humans will retain some oversight over the actions of weaponized robots, the effectiveness of that oversight is questionable, Human Rights Watch and the Harvard clinic said. Moreover, military statements have left the door open to full autonomy in the future. “Action is needed now, before killer robots cross the line from science fiction to feasibility,” Goose said.

Avatar

Mysterious Cameras on Utility Poles in New York - Under Investigation - June 1, 2012

UPDATE: http://www.youtube.com/watch?v=dazLt6q9XAY http://sheilaaliens.net/?p=766 "The office of north country Congressman Bill Owens says it's going to look into those mysterious cameras that have popped up on utility poles throughout St. Lawrence County. 7 News spent much of the day calling agencies and officials to see if they know why the cameras are there and what they're for. We spoke with the U.S. Border Patrol, which said it knew nothing about the cameras. Homeland Security didn't return our calls. Joe Gilbert, the county's new emergency services director, told 7 News that he is aware of the cameras, but declined to say anything further. He asked us to call him back later, but we've been unable to reach him." http://www.wwnytv.com/news/local/Congressman-To-Look-Into-Mysterious-Cameras-...

Source: youtube.com
Avatar

  www.tv-robotics.co.za

The Pentagon’s Defense Advanced Research Projects Agency (DARPA) plans to have fully humanoid robots that think, act, react, learn, make decisions all on their own, and live amongst us all, by the year 2025 or even sooner. We are talking only 16? years or less. Robotics is alot more important to the New World Order Agenda than a lot of people may think. The NWO knows that almost none of the police or military are actually going to turn on the citizens of their own country and enforce martial law and a police state. This is why (IMO) that robots are a crucial factor to the success of the NWO. intelligent humanoid robots are exactly what the NWO needs in order to police and enslave everyone.

Duration : 0:1:21

Avatar

A System Designed for Answers

Operating on a single CPU, it could take Watson two hours to answer a single question. This is a far cry from the three seconds it takes to be competitive on Jeopardy!. For Watson to achieve the speed of the human brain in delivering a single, precise answer to a question requires thousands of POWER7 computing cores working in a massively parallel system.

Watch the video to find out how building a smarter system like Watson involves optimizing hardware and software into a solution greater than the sum of its parts.

You are using an unsupported browser and things might not work as intended. Please make sure you're using the latest version of Chrome, Firefox, Safari, or Edge.
mouthporn.net