Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/timkong21/facebook-page-classifier
Apply Multi-class node classification algorithm to classify Facebook page content type
https://github.com/timkong21/facebook-page-classifier
biased-random-walk gensim-word2vec graph machine-learning multi-class-classification networkx node2vec stellargraph tsne
Last synced: 10 days ago
JSON representation
Apply Multi-class node classification algorithm to classify Facebook page content type
- Host: GitHub
- URL: https://github.com/timkong21/facebook-page-classifier
- Owner: TimKong21
- Created: 2021-09-12T06:12:43.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-09-12T21:48:25.000Z (over 3 years ago)
- Last Synced: 2023-08-26T17:35:43.965Z (over 1 year ago)
- Topics: biased-random-walk, gensim-word2vec, graph, machine-learning, multi-class-classification, networkx, node2vec, stellargraph, tsne
- Language: Jupyter Notebook
- Homepage:
- Size: 2.19 MB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Facebook Page Classifier
The [facebook_large dataset](https://github.com/TimKong21/Facebook-page-classifier/tree/main/facebook_large) contains page-page graph of verified Facebook sites.
This graph was collected through the Facebook Graph API in November 2017
and restricted to pages from four categories which are defined by Facebook.
Multi-class node classification on the Facebook sites is performed in this repository.## Dataset
There are nodes and edges in the dataset. They are:[musae_facebook_target.csv](https://raw.githubusercontent.com/TimKong21/Facebook-page-classifier/main/facebook_large/musae_facebook_target.csv)
- Nodes are the oficial Facebook pages with unique ids.
- Each page is labelled with the page type - **tvshow**, **government**, **company**, **politician**.[musae_facebook_edges.csv](https://raw.githubusercontent.com/TimKong21/Facebook-page-classifier/main/facebook_large/musae_facebook_edges.csv)
- Edges are the mutual likes between the Facebook pages
- There could be no relarionships, one-to-one or one-to-many relationships.## Notebook
[Facebook page classifier.ipynb](https://github.com/TimKong21/Facebook-page-classifier/blob/main/Facebook%20page%20classifier.ipynb)
contains the step for node classification. Through the process, every node is assigned a specific label. A predefined percentage of random nodes is used to train the classifier, while the rest serves as test data for evaluating the embedding method and specific classifier.
The implementation can be divided into four main steps:1. Calculate and save node embeddings for the whole graph.
2. Split the node embeddings into training and testing sets.
3. Train the classifier.
4. Evaluate the classifier on the test data.
## Acknowledgements- [Node embeddings visualization reference](https://stellargraph.readthedocs.io/en/stable/demos/node-classification/node2vec-node-classification.html)
- [Node classification algorithms reference](https://github.com/memgraph/graph-analytics-course/blob/master/lecture-5/node-classification/classifier.py)