Let us worry about your assignment instead!

We Helped With This Python Programming Assignment: Have A Similar One?

SOLVED
CategoryProgramming
SubjectPython
DifficultyUndergraduate
StatusSolved
More InfoHelp With Python Homework
88481

Short Assignment Requirements

1st part: Develop a webpage downloader program in Python 2.7. The program receives a URL pointing to a base HTML file as a command line argument, and then downloads this base file as well as all image objects referenced by that file. There is no need to download videos. Must use socket programming. (partially done, code attached)2nd part:modify the webpage downloader program in 1st part by supporting multithreading. Currently, the program makes one request at a time. Modify the program to implement a multithreaded webpage downloader capable of receiving multiple objects simultaneously. Must use socket module.

Assignment Description

Assignment:

In this project, you will modify your webpage downloader program in Project 2 by supporting multithreading. Currently, the program makes one request at a time. Modify the program to implement a multithreaded webpage downloader capable of receiving multiple objects simultaneously. You will then conduct thoughtful and detailed experiments to compare the performance of this multithreaded webpage downloader with the basic webpage downloader in Project 2.

 You will first need to read carefully and understand the technical details, specification, and the examples of multithreading at https://docs.python.org/2/library/threading.html. The following tutorial will be helpful: http://www.tutorialspoint.com/python/python_multithreading.htm.

 

 (50 Points) Now, enhance your webpage downloader in Project 2 by supporting multithreading. Your new webpage downloader must have ALL required features of that in Project 2.

 

 (50 Points) Conduct thoughtful and detailed experiments to compare the performance of this multi-threaded webpage downloader with that you developed in Project 2. You must decide on the proper performance metric to use, the type of experiments to be conducted, and how to conduct these experiments to quantitatively and adequately compare the performance of the two downloaders. In the report, you must specify your performance evaluation methodology, include the results in both well-formatted and presented tables and graphs, and briefly analyze the results.

 

What to Submit

 You must submit the complete python code.

 You must also submit a detailed report in pdf format, including a copy of the source code, testing procedure used to verify the correctness of the program, the screenshots and their explanations, performance evaluation methodology, comparative results, and their analysis. You must provide thoughtful screenshots to prove that your code works as expected. You must also demonstrate by the screenshots that the multithreading aspect works. You may want to introduce intentional time delays in the program in certain cases. Be creative!

 

Webpage Downloader Assignment-2(partially done):

Develop a webpage downloader program in Python. The program receives a URL pointing to a base HTML file as a command line argument, and then downloads this base file as well as all image objects referenced by that file. There is no need to download videos.

Code written:

 

import socket

from HTMLParser import HTMLParser

 

# Set up a TCP/IP socket

s = socket.socket(socket.AF_INET,socket.SOCK_STREAM)

 

'''Connect as client to a selected server

on a specified port'''

 

warning_ = """Type a URL, don't put any http:// or https://

infront of the url, must put a / at the end of the address: """

#example: "www.ece.eng.wayne.edu/~nabil/"

url_ = raw_input(warning_) # User will provide the URL appropriately

 

server_ = str(url_).split('/')[0] # Isolating the server from the given URL

print server_ # Printing the server name

s.connect((server_, 80)) # Establishing connection using socket

page_ = url_.replace(server_, "")

# Protocol exchange - sends and receives

s.send("GET "+page_+" HTTP/1.0") # Using GET method to request information via HTTP

file_ = open('webpage.html','w') #  Creating a blank html file

picture = "";

while True:

        resp = s.recv(4096)

        if resp == "": break

        #print resp,

        file_.write(resp) # Writing on the html file with webpage data

        picture = picture + resp

 

class MyParse(HTMLParser):

        def handle_starttag(self, tag, attrs):

            if tag=="img":

                print(dict(attrs)["src"]) # Printing the link of all image objects associated with the webpage

               

h=MyParse()

page=open('webpage.html').read()

h.feed(page)

 

# Close the connection when completed

file_.close()

s.close()

Frequently Asked Questions

Is it free to get my assignment evaluated?

Yes. No hidden fees. You pay for the solution only, and all the explanations about how to run it are included in the price. It takes up to 24 hours to get a quote from an expert. In some cases, we can help you faster if an expert is available, but you should always order in advance to avoid the risks. You can place a new order here.

How much does it cost?

The cost depends on many factors: how far away the deadline is, how hard/big the task is, if it is code only or a report, etc. We try to give rough estimates here, but it is just for orientation (in USD):

Regular homework$20 - $150
Advanced homework$100 - $300
Group project or a report$200 - $500
Mid-term or final project$200 - $800
Live exam help$100 - $300
Full thesis$1000 - $3000

How do I pay?

Credit card or PayPal. You don't need to create/have a Payal account in order to pay by a credit card. Paypal offers you "buyer's protection" in case of any issues.

Why do I need to pay in advance?

We have no way to request money after we send you the solution. PayPal works as a middleman, which protects you in case of any disputes, so you should feel safe paying using PayPal.

Do you do essays?

No, unless it is a data analysis essay or report. This is because essays are very personal and it is easy to see when they are written by another person. This is not the case with math and programming.

Why there are no discounts?

It is because we don't want to lie - in such services no discount can be set in advance because we set the price knowing that there is a discount. For example, if we wanted to ask for $100, we could tell that the price is $200 and because you are special, we can do a 50% discount. It is the way all scam websites operate. We set honest prices instead, so there is no need for fake discounts.

Do you do live tutoring?

No, it is simply not how we operate. How often do you meet a great programmer who is also a great speaker? Rarely. It is why we encourage our experts to write down explanations instead of having a live call. It is often enough to get you started - analyzing and running the solutions is a big part of learning.

What happens if I am not satisfied with the solution?

Another expert will review the task, and if your claim is reasonable - we refund the payment and often block the freelancer from our platform. Because we are so harsh with our experts - the ones working with us are very trustworthy to deliver high-quality assignment solutions on time.

Customer Feedback

"Thanks for explanations after the assignment was already completed... Emily is such a nice tutor! "

Order #13073

Find Us On

soc fb soc insta


Paypal supported