{"id":18553021,"url":"https://github.com/lunarwhite/covid-social-analysis","last_synced_at":"2025-04-09T22:32:13.208Z","repository":{"id":37203492,"uuid":"359287260","full_name":"lunarwhite/covid-social-analysis","owner":"lunarwhite","description":"Apply ML on weibo sentiment. 疫情背景下微博文本情感分析与可视化","archived":false,"fork":false,"pushed_at":"2025-03-06T06:32:25.000Z","size":45913,"stargazers_count":43,"open_issues_count":0,"forks_count":3,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-24T13:21:20.190Z","etag":null,"topics":["crawling","data-analysis","machine-learning","nlp","python","vizualization"],"latest_commit_sha":null,"homepage":"","language":"HTML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lunarwhite.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-04-19T00:54:21.000Z","updated_at":"2025-03-06T06:32:25.000Z","dependencies_parsed_at":"2024-11-23T02:35:41.107Z","dependency_job_id":null,"html_url":"https://github.com/lunarwhite/covid-social-analysis","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lunarwhite%2Fcovid-social-analysis","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lunarwhite%2Fcovid-social-analysis/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lunarwhite%2Fcovid-social-analysis/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lunarwhite%2Fcovid-social-analysis/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lunarwhite","download_url":"https://codeload.github.com/lunarwhite/covid-social-analysis/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248123810,"owners_count":21051537,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["crawling","data-analysis","machine-learning","nlp","python","vizualization"],"created_at":"2024-11-06T21:15:51.170Z","updated_at":"2025-04-09T22:32:08.194Z","avatar_url":"https://github.com/lunarwhite.png","language":"HTML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# covid-social-analysis\n\n![GitHub Repo stars](https://img.shields.io/github/stars/lunarwhite/covid-social-analysis?color=orange)\n![GitHub watchers](https://img.shields.io/github/watchers/lunarwhite/covid-social-analysis?color=yellow)\n![GitHub forks](https://img.shields.io/github/forks/lunarwhite/covid-social-analysis?color=green)\n![GitHub top language](https://img.shields.io/github/languages/top/lunarwhite/covid-social-analysis)\n![GitHub License](https://img.shields.io/github/license/lunarwhite/covid-social-analysis?color=white)\n\nML-based analysis of social media user attentiveness of COVID-19. 应用机器学习分析疫情背景下的微博文本情感\n\n更多细节请看此 [blog post](https://lunarwhite.notion.site/COVID-19-fffa5d93ce2c46bf98fe2e10a7091d00)\n\n```\n├───res\n│   ├───input\n│   │   ├───comment # 评论数据\n│   │   ├───dict # 词典\n│   │   ├───hot # 热词\n│   │   ├───SOPMI\n│   │   ├───stage # 不同阶段微博数据\n│   │   └───topic # 微博数据\n│   └───output\n│       ├───clustering\n│       │   ├───cluster-num # 聚类数\n│       │   ├───image1 # 聚类分析饼图\n│       │   └───image2 # 聚类数\n│       ├───comment-txt # 评论数据-txt\n│       ├───emotion-dict\n│       │   └───image # 情感对比图\n│       ├───hot\n│       ├───multi-emotion\n│       │   └───image # 多维情感分析图\n│       └───topic-txt # 微博数据-txt\n└───src\n    ├───01crawling # 爬取数据\n    ├───02preprocessing # 预处理\n    ├───03analysis #分析\n    │   ├───clustering # 聚类\n    │   ├───emotion-dict # 情感词典\n    │   └───multi-emotion # 多维情感\n    └───04visualization # 可视化\n        ├───clustering\n        ├───emotion-dict\n        └───multi-emotion\n```\n\n## 1 Overview\n\n- 手动爬取疫情背景下微博文本与评论，进行情感分析\n- 分别尝试聚类、情感词典和多维度情感分析\n- 主要工具包版本为 Python `3.6.10` 和 scikit-learn `0.24.2`\n\n## 2 Setup\n\n- clone repo：`git clone https://github.com/lunarwhite/covid-social-analysis.git`\n- 更新 pip：`pip3 install --upgrade pip`\n- 为项目创建虚拟环境：`conda create --name \u003cenv_name\u003e python=3.6`\n- 激活 env：`conda activate \u003cenv_name\u003e`\n- 安装 Python 库依赖：`pip3 install -r requirements.txt`\n\n## 3 Workflow\n\n- 数据获取\n  - 爬取微博文本\n  - 爬取微博评论\n- 数据预处理\n  - 数据清洗\n  - 去停用词\n  - jieba 分词\n  - textRank 关键词分析\n- 分析-情感词典\n  - SO-PMI 新词发现\n  - 心态词典扩展\n  - 心态值计算\n- 分析-聚类\n  - K-means 聚类\n  - DBSCAN 聚类\n  - 层次聚类\n- 分析-多维度分析\n  - 多维心态词典\n  - 多维情感分析\n- 可视化\n  - pyecharts\n  - matplotlib\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flunarwhite%2Fcovid-social-analysis","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flunarwhite%2Fcovid-social-analysis","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flunarwhite%2Fcovid-social-analysis/lists"}