Package: transforEmotion 0.1.7

transforEmotion: Sentiment Analysis for Text, Image and Video using Transformer Models

Implements sentiment analysis using huggingface <https://huggingface.co> transformer zero-shot classification model pipelines for text and image data. The default text pipeline is Cross-Encoder's DistilRoBERTa <https://huggingface.co/cross-encoder/nli-distilroberta-base> and default image/video pipeline is Open AI's CLIP <https://huggingface.co/openai/clip-vit-base-patch32>. All other zero-shot classification model pipelines can be implemented using their model name from <https://huggingface.co/models?pipeline_tag=zero-shot-classification>.

Authors:Alexander Christensen [aut], Hudson Golino [aut], Aleksandar Tomašević [aut, cre]

transforEmotion_0.1.7.tar.gz
transforEmotion_0.1.7.zip(r-4.7)transforEmotion_0.1.7.zip(r-4.6)transforEmotion_0.1.7.zip(r-4.5)
transforEmotion_0.1.7.tgz(r-4.6-any)transforEmotion_0.1.7.tgz(r-4.5-any)
transforEmotion_0.1.7.tar.gz(r-4.7-any)transforEmotion_0.1.7.tar.gz(r-4.6-any)
transforEmotion_0.1.7.tgz(r-4.6-emscripten)
manual.pdf |manual.html
DESCRIPTION |NEWS
card.svg |card.png
transforEmotion/json (API)

# Install 'transforEmotion' in R:
install.packages('transforEmotion', repos = c('https://atomashevic.r-universe.dev', 'https://cloud.r-project.org'))

Bug tracker:https://github.com/atomashevic/transforemotion/issues

Datasets:

On CRAN:

Conda:

6.96 score 38 stars 20 scripts 716 downloads 40 exports 85 dependencies

Last updated from:92c89ab801. Checks:7 WARNING, 2 OK. Indexed: yes.

TargetResultTimeFilesSyslog
linux-devel-x86_64WARNING171
source / vignettesOK257
linux-release-x86_64WARNING229
macos-release-arm64WARNING153
macos-oldrel-arm64WARNING212
windows-develWARNING139
windows-releaseWARNING137
windows-oldrelWARNING152
wasm-releaseOK172

Exports:.init_builtin_modelsadd_vision_modelas_rag_tablecheck_findingemo_qualitydelete_transformerdlo_dynamicsdownload_findingemo_dataemoxicon_scoresevaluate_emotionsget_vision_model_configimage_scoresimage_scores_diris_vision_model_registeredlist_vision_modelsload_findingemo_annotationsmap_discrete_to_vadmap_to_emo8nlp_scoresparse_rag_jsonplot_sim_emotionsprepare_findingemo_evaluationpunctuateragrag_sentemoregister_retrieverregister_vision_modelremove_vision_modelsentence_similaritysetup_gpu_modulessetup_minicondasetup_modulessetup_popular_modelsshow_vision_modelssimulate_videote_cleanup_default_venvtransformer_scoresvad_scoresvalidate_rag_jsonvalidate_rag_predictionsvideo_scores

Dependencies:askpassbase64encbitbit64bslibcachemclicliprcpp11crayoncurldigestdplyrevaluatefarverfastmapfontawesomefsgarglegenericsggplot2gluegoogledrivegtableherehighrhmshtmltoolshtmlwidgetshttrisobandjquerylibjsonliteknitrlabelinglatticelifecyclelsaLSAfunmagrittrMatrixmemoisemimeopensslpbapplypillarpkgconfigplyrpngprettyunitsprogresspurrrR6rappdirsRColorBrewerRcppRcppTOMLreadrremotesreshape2reticulaterglrlangrmarkdownrprojrootS7sassscalesSnowballCstringistringrsystextdatatibbletidyselecttinytextzdbutf8uuidvctrsviridisLitevroomwithrxfunyaml

Evaluating Emotion Classification with evaluate_emotions()
Introduction | Installation and Setup | Basic Usage | Creating Sample Data | Basic Evaluation | Evaluation with Probabilities | Understanding the Metrics | Classification Metrics | Probabilistic Metrics | Inter-rater Reliability | Visualization | Integration with transforEmotion Workflow | Complete Pipeline Example | Using with CSV Data | Advanced Usage | Custom Metrics Selection | Handling Missing Data | Custom Column Names | Best Practices | 1. Always Include Probability Scores | 2. Use Appropriate Metrics | 3. Validate Data Quality | 4. Report Multiple Metrics | Conclusion

Last update: 2025-09-16
Started: 2025-09-16

Setup and Tutorial
1. Python setup using setup_miniconda() | 2. Using transformer_scores | 3. Using image_scores | 4. Using `video_scores'

Last update: 2024-01-09
Started: 2022-04-13

Readme and manuals

Help Manual

Help pageTopics
transforEmotion-packagetransforEmotion-package transforEmotion
Initialize Built-in Vision Models.init_builtin_models
Vision Model Registry for transforEmotion Package.vision_model_registry
User-Friendly Vision Model Management Functionsadd_vision_model
Convert RAG JSON to a tableas_rag_table
Calculate the moving average for a time seriescalculate_moving_average
Check FindingEmo Dataset Qualitycheck_findingemo_quality
Install Necessary Python Modulescheck_nvidia_gpu
Delete a Transformer Modeldelete_transformer
Dynamics function of the DLO modeldlo_dynamics
Download FindingEmo-Light Datasetdownload_findingemo_data
Emotions Dataemotions
Emoxicon Scoresemoxicon_scores
Generate and emphasize sudden jumps in emotion scoresemphasize
Evaluate Emotion Classification Performanceevaluate_emotions
Generate observable emotion scores data from latent variablesgenerate_observables
Generate a matrix of Dynamic Error values for the DLO simulationgenerate_q
Get Vision Model Configurationget_vision_model_config
Calculate image scores using a Hugging Face CLIP modelimage_scores
Calculate image scores for all images in a directory (fast batch)image_scores_dir
Check if Vision Model is Registeredis_vision_model_registered
List Available Vision Modelslist_vision_models
Load FindingEmo-Light Annotationsload_findingemo_annotations
Map Discrete Emotions to VAD (Valence-Arousal-Dominance) Frameworkmap_discrete_to_vad
Map FindingEmo Emotions to Emo8 Labelsmap_to_emo8
Multivariate Normal (Gaussian) DistributionMASS_mvrnorm
NEO-PI-R IPIP Extraversion Item Descriptionsneo_ipip_extraversion
Natural Language Processing Scoresnlp_scores
Parse RAG JSONparse_rag_json
Plot the latent or the observable emotion scores.plot_sim_emotions
Plot Evaluation Resultsplot.emotion_evaluation
Prepare FindingEmo Data for Evaluationprepare_findingemo_evaluation
Print method for emotion evaluation resultsprint.emotion_evaluation
Punctuation Removal for Textpunctuate
Retrieval-augmented Generation (RAG)rag
RAG JSON utilitiesrag_json_utils
Structured Emotion/Sentiment via RAG (Small LLMs)rag_sentemo
Register a custom retrieverregister_retriever
Register a Vision Modelregister_vision_model
Remove a Vision Modelremove_vision_model
Sentiment Analysis Scoressentence_similarity
Install GPU Python Modulessetup_gpu_modules
Deprecated: Miniconda setup (use uv instead)setup_miniconda
Setup Required Python Modulessetup_modules
Quick Setup for Popular Modelssetup_popular_models
Show Available Vision Modelsshow_vision_models
Simulate latent and observed emotion scores for a single "video"simulate_video
Stop Words from the _tm_ Packagestop_words
Summary method for emotion evaluation resultssummary.emotion_evaluation
Remove reticulate's default virtualenv (r-reticulate)te_cleanup_default_venv
Russian Trolls Data - Small Versiontinytrolls
Sentiment Analysis Scorestransformer_scores
Direct VAD (Valence-Arousal-Dominance) Predictionvad_scores
Validate a RAG JSON structurevalidate_rag_json
Validate RAG Emotion/Sentiment Predictionsvalidate_rag_predictions
Run FER on a YouTube video using a Hugging Face CLIP modelvideo_scores