Algorithms For Dummies


Getting the Right Web page



Download 7,18 Mb.
Pdf ko'rish
bet371/651
Sana15.07.2021
Hajmi7,18 Mb.
#120357
1   ...   367   368   369   370   371   372   373   374   ...   651
Bog'liq
Algorithms

  Getting the Right Web page 

     215


there are no arrows, but the direction of an edge is represented by a thicker line 

entering a node. For example, a surfer can go from node 4 to node 6 because there 

is a thick line entering node 6 from node 4. However, the surfer can’t go from 

node 6 to node 4 because the line entering node 4 from node 6 is thin.

The second graph isn’t strongly connected. It presents a trap for a random surfer 

because the second node has no outbound links, and a user visiting the page could 

stop there and find no way out. This isn’t an unusual event considering the struc-

ture of the web, but it could also show a spammer artifact, such that the spammer 

created a spam factory with many links that direct to a dead end site in order to 

trap web surfers. Figure 11-2 shows the output of the following code, which was 

used to display this graph.

np.random.seed(2)

pos=nx.shell_layout(Graph_B)

nx.draw(Graph_B, pos, arrows=True, with_labels=True)

plt.show()

Another situation that may be natural or the result of a spammer’s action is a 

spider trap. It’s another dead end for a surfer, this time not on a single page but 

on a closed site that lacks links to an outside network of pages. Figure 11-3 shows 

the output of the following code, which was used to display this graph.

np.random.seed(2)

pos=nx.shell_layout(Graph_C)

nx.draw(Graph_C, pos, arrows=True, with_labels=True)

plt.show()

FIGURE 11-2: 

A dead end.




216

 

   


  PART 3 


Download 7,18 Mb.

Do'stlaringiz bilan baham:
1   ...   367   368   369   370   371   372   373   374   ...   651




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©hozir.org 2025
ma'muriyatiga murojaat qiling

kiriting | ro'yxatdan o'tish
    Bosh sahifa
юртда тантана
Боғда битган
Бугун юртда
Эшитганлар жилманглар
Эшитмадим деманглар
битган бодомлар
Yangiariq tumani
qitish marakazi
Raqamli texnologiyalar
ilishida muhokamadan
tasdiqqa tavsiya
tavsiya etilgan
iqtisodiyot kafedrasi
steiermarkischen landesregierung
asarlaringizni yuboring
o'zingizning asarlaringizni
Iltimos faqat
faqat o'zingizning
steierm rkischen
landesregierung fachabteilung
rkischen landesregierung
hamshira loyihasi
loyihasi mavsum
faolyatining oqibatlari
asosiy adabiyotlar
fakulteti ahborot
ahborot havfsizligi
havfsizligi kafedrasi
fanidan bo’yicha
fakulteti iqtisodiyot
boshqaruv fakulteti
chiqarishda boshqaruv
ishlab chiqarishda
iqtisodiyot fakultet
multiservis tarmoqlari
fanidan asosiy
Uzbek fanidan
mavzulari potok
asosidagi multiservis
'aliyyil a'ziym
billahil 'aliyyil
illaa billahil
quvvata illaa
falah' deganida
Kompyuter savodxonligi
bo’yicha mustaqil
'alal falah'
Hayya 'alal
'alas soloh
Hayya 'alas
mavsum boyicha


yuklab olish