AI Generated Art

Background

AI is all the buzz and hype these days. From chatGPT to DALL-E (both OpenAI projects). I decided to see what it’s all about. I created an account on openai.com and set out to try a few things.

ChatGPT

So I tried some interaction with ChatGPT. I asked it about what role AI will increasingly take in society:

Artificial intelligence (AI) is expected to play an increasingly large role in many aspects of society. Some possible areas where AI could have a big impact include:

  1. Automation of jobs: AI-powered machines and software can automate many tasks that are currently performed by humans, which could lead to increased productivity but also job displacement.
  2. Healthcare: AI could be used to analyze medical data and assist doctors in making diagnoses and treatment plans.
  3. Transportation: AI could be used to improve the efficiency and safety of cars, trucks, and public transportation systems.
  4. Finance: AI could be used to detect fraud, make investment decisions, and provide financial advice.
  5. Education: AI could be used to personalize learning experiences and provide teachers with valuable insights into student progress.
  6. Research: AI could be used to analyze data and make new scientific discoveries.
  7. Social media and entertainment: AI could be used to create more personalized content and improve the overall user experience.
  8. Environmental monitoring and management : AI can assist with monitoring resources, analyzing data and identifying patterns that can be utilized to take proactive measures to mitigate environmental damage

It’s important to note that AI’s potential impact can be both positive and negative, and it will be important for society to carefully consider how to use AI in a way that maximizes its benefits and minimizes its drawbacks.

Overall, AI is expected to drive efficiency and productivity across a wide range of industries, and it could also lead to the creation of new products and services that we can’t yet imagine.

–ChatGPT

Ok, at least it’s honest about the positive AND negative impacts that AI brings. Now I asked it to generate Python code to parse a json weather string and store values to a MySQL database:

AI Request:

python code to parse json string {“timestamp”:1673474094,”air_temperature”:14.0,”barometric_pressure”:1005.4,”relative_humidity”:64,”precip”:0.0,”precip_accum_local_day”:0.0,”wind_avg”:0.1,”wind_direction”:103,”wind_gust”:1.0,”wind_lull”:0.0,”uv”:0.09,”brightness”:2026,”feels_like”:14.0,”heat_index”:14.0,”wind_chill”:14.0,”dew_point”:7.3,”air_density”:1.21972} and store data in mysql database called weather

And the generated Python code given was:

import json
import mysql.connector

# Parse JSON string
data = json.loads('{"timestamp":1673474094,"air_temperature":14.0,"barometric_pressure":1005.4,"relative_humidity":64,"precip":0.0,"precip_accum_local_day":0.0,"wind_avg":0.1,"wind_direction":103,"wind_gust":1.0,"wind_lull":0.0,"uv":0.09,"brightness":2026,"feels_like":14.0,"heat_index":14.0,"wind_chill":14.0,"dew_point":7.3,"air_density":1.21972}')

# Connect to MySQL database
cnx = mysql.connector.connect(user='username', password='password', host='hostname', database='weather')
cursor = cnx.cursor()

# Prepare SQL query
query = "INSERT INTO weather_data (timestamp, air_temperature, barometric_pressure, relative_humidity, precip, precip_accum_local_day, wind_avg, wind_direction, wind_gust, wind_lull, uv, brightness, feels_like, heat_index, wind_chill, dew_point, air_density) VALUES (%s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s, %s)"

# Extract data from parsed JSON
values = (data["timestamp"], data["air_temperature"], data["barometric_pressure"], data["relative_humidity"], data["precip"], data["precip_accum_local_day"], data["wind_avg"], data["wind_direction"], data["wind_gust"], data["wind_lull"], data["uv"], data["brightness"], data["feels_like"], data["heat_index"], data["wind_chill"], data["dew_point"], data["air_density"])

# Execute SQL query
cursor.execute(query, values)

# Commit changes to the database
cnx.commit()

# Close cursor and connection
cursor.close()
cnx.close()

The AI offered this suggestion after generating the above code:

Make sure you have installed mysql connector python using pip and have a running mysql server and have created the table weather_data in the weather database with same column names as in the SQL query. This code snippet assumes you have the connection details for the MySQL server. Replace “username”, “password”, “hostname” with the appropriate values for your setup and also check the table name and column name of your table if it different.

–ChatGPT

DALL-E

So the txt/chat version of the AI was impressive, now to try generating some images. Here’s what I was able to generate – each request appears in the image captions below:

“Photo of stargate to another world”
“oil painting of UFO in a cheeseburger against dark background”
“early spring morning in the wilderness with green grassy fields, trees, and blue sky digital art”
“digital art of teenagers doing pranks”
“A bowl of soup that is also a portal to another dimension, digital art”
“Oil painting of AI robot in steampunk room”
“oil painting of inside of downtown coffee shop with steampunk decor”
“A 3D render of a rainbow colored hot air balloon flying above a reflective lake”
“steampunk room”

So I wonder: Who owns the rights to these images? They were created by the AI based on input I had given. Are they mine? Or does OpenAI own these? What do you think? Sound off in the comments below, and give your thoughts. I bet this is one area where it will take a while for legal experts to define.

Leave a Reply

Your email address will not be published. Required fields are marked *