Create a jes function

Assignment Help Python Programming
Reference no: EM13739577

All of your code must be in a single JY file named assignment2.jy. Each of the following levels (except level 0, which is not code) must be attempted in its own function (e.g. level 1 in level1(), etc.).

While you are permitted to create helper/utility functions that may be shared between the different levels, there must not be any direct interactions between the functions of different levels. E.g. level2() must never call level1(), etc. While this may not be ideal, if there is an issue with one level, we can still mark the other levels for what they are.

Level 0: Data preparation

Before any coding, prepare your data based on the given guidelines. You must create at least one character image (needed for level 1) and at least one image containing the text to detect. The text to detect must contain at least two occurrences of the chosen character and as shown must be just a single row of text.

Level 1: Detect instances of one character

Create a JES function named level1() and include the relevant behaviours. Specifically, in this level, you only need to detect just one character from the text and the text is only in a single row. The text image needs to have at least two occurrences of the character that you have chosen to detect.

Level 2: Detect all characters including space

Copy, paste and extend your level1() in a function named level2() so that all characters (uppercase A to Z and space) can be detected.

Hint: There is no need to use lists for level 2 (see level 3) but there will be a lot of code repetition (which is permitted for this level).

Tip 1: Look up "QUICK BROWN FOX..." (or similar) when preparing your text image to detect.

Tip 2: As having one image file per character mask can be tedious, feel free (but it is not a requirement) to create a single image with characters A-Z and "extract" the masks from that. You can manually enter/assume the bounding coordinates of each character.

Level 3: Using lists/arrays

Copy, paste and extend the level2() function in a function named level3() for this level. You must now store the character mask picture objects for A to Z and the space character in a list/array. This should significantly reduce code repetition that you would have in level 2.

 

Reference no: EM13739577

Questions Cloud

What you learned from the research in the articles : What connections and or confirmations can you make between the results of your interview and what you learned from the research in the articles?
What institutions are playing a role in greeces future : Greece is trying to re-establish its power within a complex system of regional and international organizations. Describe Greece's situation. What institutions are playing a role in Greece's future? Are there other institutions and factors affecting t..
Bargaining power of suppliers : Before writing your response, using the textbook and knowledge you have about the airline industry, complete the industry analysis. Provide a rating for each area and provide a short justification for the rating: Rate High, Medium, Medium to Low, or..
Competitors on factors important in the industry : Question 1: Critical-Success-Factor (CSF) analysis is one of the few analytical tools available to compare one's company with its competitors on factors important in the industry.
Create a jes function : Create a JES function named level1() and include the relevant behaviours. Specifically, in this level, you only need to detect just one character from the text and the text is only in a single row.
What is the effective annual rate : You credit card statement says that you will be charged 1.05% interest a month on unpaid balances. What is the Effective Annual Rate (EAR) being charged
Debate about whether high employment rates : Currently there is a debate about whether high employment rates in the US are the result of cyclical factors or structural factors. Describe this debate? What impact might immigration have on the different types of unemployment?
Income taxes affect aggregate demand : Which of the following was not a cause of the U.S. budget deficits in the 1980s? Which of the following does not qualify as an automatic stabilizer? Income taxes affect aggregate demand. Which of the following constitutes a direct tax?
All organizational learning disabilities : Identify a current organization that is not, in your opinion, a Learning Organization. Your are to develop a presentation and supporting paper that will describe how, through a Systems View

Reviews

Write a Review

Python Programming Questions & Answers

  Write a python program to implement the diff command

Without using the system() function to call any bash commands, write a python program that will implement a simple version of the diff command.

  Write a program for checking a circle

Write a program for checking a circle program must either print "is a circle: YES" or "is a circle: NO", appropriately.

  Prepare a python program

Prepare a Python program which evaluates how many stuck numbers there are in a range of integers. The range will be input as two command-line arguments.

  Python atm program to enter account number

Write a simple Python ATM program. Ask user to enter their account number, and print their initail balance. (Just make one up). Ask them if they wish to make deposit or withdrawal.

  Python function to calculate two roots

Write a Python function main() to calculate two roots. You must input a,b and c from keyboard, and then print two roots. Suppose the discriminant D= b2-4ac is positive.

  Design program that asks user to enter amount in python

IN Python Design a program that asks the user to enter the amount that he or she has budget in a month. A loop should then prompt the user to enter his or her expenses for the month.

  Write python program which imports three dictionaries

Write a Python program called hours.py which imports three dictionaries, and uses the data in them to calculate how many hours each person has spent in the lab.

  Write python program to create factors of numbers

Write down a python program which takes two numbers and creates the factors of both numbers and displays the greatest common factor.

  Email spam filter

Analyze the emails and predict whether the mail is a spam or not a spam - Create a training file and copy the text of several mails and spams in to it And create a test set identical to the training set but with different examples.

  Improve the readability and structural design of the code

Improve the readability and structural design of the code by improving the function names, variables, and loops, as well as whitespace. Move functions close to related functions or blocks of code related to your organised code.

  Create a simple and responsive gui

Please use primarily PHP or Python to solve the exercise and create a simple and responsive GUI, using HTML, CSS and JavaScript.Do not use a database.

  The program is to print the time

The program is to print the time in seconds that the iterative version takes, the time in seconds that the recursive version takes, and the difference between the times.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd