Coder Social home page Coder Social logo

olha-kaminska / frnn_emotion_detection Goto Github PK

View Code? Open in Web Editor NEW
7.0 1.0 2.0 378 KB

Code for 3 papers: 1) "Fuzzy-Rough Nearest Neighbour Approaches for Emotion Detection in Tweets"; 2) "LT3 at SemEval-2022 Task 6: Fuzzy-Rough Nearest neighbor Classification for Sarcasm Detection"; 3) "Fuzzy Rough Nearest Neighbour Methods for Detecting Emotions, Hate Speech and Irony" by O. Kaminska, Ch. Cornelis and V. Hoste.

Jupyter Notebook 66.67% Python 33.33%
frnn frnn-owa fuzzy-logic fuzzy-rough-set conference-paper machine-learning nlp nlp-machine-learning text-classification text-processing

frnn_emotion_detection's Introduction

Fuzzy-Rough Nearest Neighbour Approaches for Emotion Detection in Tweets

Code for the paper written by Olha Kaminska, Chris Cornelis, and Veronique Hoste and presented at IJCRS 2021 conference, organized jointly with IFSA-EUSFLAT 2021.

The task is based on SemEval-2018 Task 1: Affect in Tweets competition. We chose the ordinal classification Task EI-oc: Detecting Emotion Intensity.

Repository Overview

  • The code directory contains .py files with different functions:
    • data_preprocessing.py - functions for data uploading and preperation;
    • frnn_owa_eval.py - functions for FRNN-OWA approach and cross-validation;
    • tweets_embedding.py - functions for tweets embeddings with different methods.
  • The data directory contains README_data_download.md file with instruction on uploading necessary dataset files that should be saved in the data folder.
  • The model directory contains README_model_download.md file with instruction on uploading necessary models that should be saved in the model folder.
  • The file Test.ipynb provides an overview of all function and their usage. It is built as a pipeline describes in the paper with corresponded results.
  • The file requirements.txt contains the list of all necessary packages and versions used with the Python 3.7.4 environment.

Arxiv link

https://arxiv.org/abs/2107.05392

BibTex citation

@inproceedings{kaminska2021fuzzy, title={Fuzzy-Rough Nearest Neighbour Approaches for Emotion Detection in Tweets}, author={Kaminska, Olha and Cornelis, Chris and Hoste, Veronique}, booktitle={International Joint Conference on Rough Sets}, pages={231--246}, year={2021}, organization={Springer} }

Abstract

Social media are an essential source of meaningful data used in different tasks such as sentiment analysis and emotion recognition. Mostly, these tasks are solved with deep learning methods. Due to the fuzzy nature of textual data, we consider using classification methods based on fuzzy rough sets.

Specifically, we develop an approach for the SemEval-2018 emotion detection task, based on the fuzzy rough nearest neighbour (FRNN) classifier enhanced with ordered weighted average (OWA) operators. We use tuned ensembles of FRNN-OWA models based on different text embedding methods. Our results are competitive with the best SemEval solutions based on more complicated deep learning methods.

frnn_emotion_detection's People

Contributors

olha-kaminska avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

frnn_emotion_detection's Issues

How to get models from NNSearch? Should there be an NNSearch abstract class before the Cosine class?

  • I'm trying to classify data with Doc2Vec and FRNN-OWA methods. For the FRNN-OWA code I tried to implement from your code: frnn_owa_eval.py , but when I try to run the Cosine class I get an error: type object 'NNSearch' has no attribute 'Model'
  • Then I tried to git clone https://github.com/oulenz/fuzzy-rough-learn.git , and it worked when running the Cosine class. But when I try to run the accuracy command which calls the 'cross_validation_ensemble_owa' function, an error appears: AttributeError: 'Model' object has no attribute 'X_T' . It was from the Cosine class.

image

Error: type object 'NNSearch' has no attribute 'Model'

I am currently experiencing an issue while attempting to execute the frnn_owa_eval.py script. The error message I encounter is: AttributeError: type object 'NNSearch' has no attribute 'Model'. I have already verified that I am using the latest version of the repository and have installed all the required packages, but the problem persists. Additionally, I attempted to install the package by cloning the repository at https://github.com/oulenz/fuzzy-rough-learn.git (version 0.2.2 as of today), but encountered a different error this time: ModuleNotFoundError: No module named 'frlearn'.

any guidance on how to resolve this problem?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.