Upload
adrmlch
View
223
Download
0
Embed Size (px)
Citation preview
8/11/2019 Scraping Techniques to Extract Advertisements From
1/27
mailto:[email protected]:[email protected]8/11/2019 Scraping Techniques to Extract Advertisements From
2/27
Scraping techniques applied to contextual advertising
Background
What is scraping?
The form of scraping The most famous scraping techniques
Application of scraping techniques
to contextual advertising
Conclusions
8/11/2019 Scraping Techniques to Extract Advertisements From
3/27
Ad Network
UsersWeb page
Ads
Online advertising is a major source
of income for most of the websites currently online
8/11/2019 Scraping Techniques to Extract Advertisements From
4/27
Sponsored Search
Contextual Advertising
The Adopted Techniques
8/11/2019 Scraping Techniques to Extract Advertisements From
5/27
Sponsored Search
8/11/2019 Scraping Techniques to Extract Advertisements From
6/27
Sponsored Search
Web Site Design
Web Site,Design
8/11/2019 Scraping Techniques to Extract Advertisements From
7/27
The contextual advertising is the
integration of content (text) and advertising information(text)
8/11/2019 Scraping Techniques to Extract Advertisements From
8/27
S i d i i i
8/11/2019 Scraping Techniques to Extract Advertisements From
9/27
Scraping advertising is
a technique to obtain ads from a Web page
8/11/2019 Scraping Techniques to Extract Advertisements From
10/27
Whats the scraping?
8/11/2019 Scraping Techniques to Extract Advertisements From
11/27
Web scraping is the process of
automatically collecting Web
information
8/11/2019 Scraping Techniques to Extract Advertisements From
12/27
The most famous scraping techniques
8/11/2019 Scraping Techniques to Extract Advertisements From
13/27
The most famous scraping techniques
8/11/2019 Scraping Techniques to Extract Advertisements From
14/27
Beautiful Soup
8/11/2019 Scraping Techniques to Extract Advertisements From
15/27
Mechanize
8/11/2019 Scraping Techniques to Extract Advertisements From
16/27
Application of scraping techniques
to contextual advertising
8/11/2019 Scraping Techniques to Extract Advertisements From
17/27
url
titoloGiven
a generic page
the
module extract
s the p inlink
Each inlink is
displayed
with the title
and url
Application of scraping techniques
to contextual advertising
8/11/2019 Scraping Techniques to Extract Advertisements From
18/27
It analyzesAnd performs scraping
I Scraping the Source Code
Application of scraping techniques
to contextual advertising
8/11/2019 Scraping Techniques to Extract Advertisements From
19/27
tobeparsed = mechanize.urlopen(url)
body = BeautifulSoup.BeautifulSoup(tobeparsed)
body = body.prettify()
body = body[:body.find('')]
link = body[body.find('')+len('--
>'):body.find('')]
link = link.replace(''',"'")
link = link.split()
control = control.split()
Application of scraping techniques
to contextual advertising
8/11/2019 Scraping Techniques to Extract Advertisements From
20/27
The extracted adsare then
randomly
selected anddisplayed in the
target Web Page
Application of scraping techniques
to contextual advertising
8/11/2019 Scraping Techniques to Extract Advertisements From
21/27
Case study: www.crastulo.it
8/11/2019 Scraping Techniques to Extract Advertisements From
22/27
Case study: www.crastulo.it
Extracting inlinkfrom :
www.crastulo.it
8/11/2019 Scraping Techniques to Extract Advertisements From
23/27
Case study: www.crastulo.it
8/11/2019 Scraping Techniques to Extract Advertisements From
24/27
Case study: www.crastulo.it
Heres the
fourrandomly
selectedads
8/11/2019 Scraping Techniques to Extract Advertisements From
25/27
Conclusions
This project was aimed at suggesting suitableads to a given Web page
To this end I devised a system written in
Python that:
extracts a set of inlinks of a given Web
page
randomly selects four ads previously
extracted by scraping
8/11/2019 Scraping Techniques to Extract Advertisements From
26/27
Future work
To apply scraping techniques also fordynamic advertising
To suggest ads according to users interests
Thanks to all
8/11/2019 Scraping Techniques to Extract Advertisements From
27/27
Thanks to
Contact Eloisa Vargiu for details and
questions on contextual advertising :
Contact us for details and questions on
scraping in Python:
Contact
mailto:[email protected]:[email protected]:[email protected]:[email protected]:[email protected]:[email protected]://www.ersucagliari.it/http://www.unica.it/