Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

input image: Modify the map-mapking program from Lab 4 to create a topographic map (highlighting the points that have elevations that are multiples of 10).

image text in transcribed

input image:

image text in transcribed

Modify the map-mapking program from Lab 4 to create a topographic map (highlighting the points that have elevations that are multiples of 10). Your program should create a new image, called topo.png with the pixels colored as follows: If the elevation is less than or equal to 0, color the pixel 25% blue (and 0% red and 0% green). If the elevation is divisible by 10, color the pixel black (0% red, 0% green, and 0% blue). Otherwise, the pixel should be colored 50% red, 50% green, and 50% blue. o o Your resulting map should look like 200 300 400 100 400 and be saved to a file called topo png. Note: before submitting your program for grading, remove the commands that show the image (i.e. the ones that pop up the graphics window with the image) The program is graded on a server on the cloud and does not have a graphics window, so, the plt.show(o and plt.imshow) commands will give an error. Instead, the files your program produces are compared pixel-by-pixel to the answer to check for correctness Modify the map-mapking program from Lab 4 to create a topographic map (highlighting the points that have elevations that are multiples of 10). Your program should create a new image, called topo.png with the pixels colored as follows: If the elevation is less than or equal to 0, color the pixel 25% blue (and 0% red and 0% green). If the elevation is divisible by 10, color the pixel black (0% red, 0% green, and 0% blue). Otherwise, the pixel should be colored 50% red, 50% green, and 50% blue. o o Your resulting map should look like 200 300 400 100 400 and be saved to a file called topo png. Note: before submitting your program for grading, remove the commands that show the image (i.e. the ones that pop up the graphics window with the image) The program is graded on a server on the cloud and does not have a graphics window, so, the plt.show(o and plt.imshow) commands will give an error. Instead, the files your program produces are compared pixel-by-pixel to the answer to check for correctness

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

DB2 9 For Linux UNIX And Windows Advanced Database Administration Certification Certification Study Guide

Authors: Roger E. Sanders, Dwaine R Snow

1st Edition

1583470808, 978-1583470800

Students also viewed these Databases questions

Question

6. Yoshi Yamamoto is a patient at St. Lukes Hospital. T F ?

Answered: 1 week ago