Skip to main content

Introduction

RNAmotiFold is an RNA secondary structure prediction algorithm that parallely recognizes RNA 3D Motifs through sequence matching. It comes pre-set with a number of motifs build into the algorithm, which are taken from the RNA 3D Motif Atlas. Also provided is a manually extracted set of RNA 3D Motifs from the Rfam database available as well. You can add your own custom motifs as csv files, the required formatting for hairpin, internal and bulge loops is shown in the respective commandline arguments when calling -h. This repository contains the code for same named Python Package, which I wrote to make the algorithm more accessible and to implement it into python scripts. The underlying algorithms for RNAmotiFold, RNAmotiCes and RNAmotiAlign are written in Bellman's GAP, translated into C++, and then compiled. The prediction is thus separate from python, keeping it as efficient as possible. You can either clone this repo, or directly install it from PyPI. This package comes with a python wrapper (RNAmotiFold.py) for the underlying algorithms implemented in Bellman's GAP. If you want to directly work with the compiled algorithm binaries, I recommend taking a look at the RNALoops repo. These lack several features though, including the single motif mode, which is implemented as part of this python package. If you have any questions please reach out to me through my public email address: marius.sebeke@ibmg.uni-stuttgart.de


Dependencies

Tested on the following dependencies:

  • Modified Bellman's GAP compiler gapcM == 2026.09.26
  • perl interpreter == perl v5.38.2
  • Python interpreter == Python 3.12.3
  • ubuntu == 24.04

Setup

The RNAmotiFold python wrapper requires the modified Bellman's GAP compiler gapcM, along with it's dependencies and a perl interpreter, to be installed. If the modified Bellman's GAP compiler or perl interpreter is not installed system wide it's location can be supplied using the --gapc_path/--perl_path option. Also if your GNU make is not installed system wide it can also be supplied with --make_path. If any of these are not supplied, the script will look try to find them on its own. RNAmotiFold is compatible with most UNIX systems, but it is not windows compatible. Unfortunately it is currently not available for Mac Systems, though a port might come in the future. No admin right are required for either the modified Bellman's GAP compiler or RNAmotiFold. These dependencies are only required on first use, they are no longer required after the installation of the algorithm binaries. Installation Guide:

  1. Either directly install RNAmotiFold from PyPI or clone this repository with git clone https://github.com/RNABioInfo/RNAmotiFold.git --recurse-submodules and install it into your virtual environment with pip install . from the base RNAmotiFold directory.
  2. The python wrapper will now be installed, but the compiled RNA secondary structure prediction algorithms are still missing. To set them up, run the RNAmotiFold_installer script and supply the dependencies through their associated commandline arguments (e.g. path to your modified GAPC to --gapc_path ). All three install dependencies are also searched for on your system if they are not supplied, using shutil.which and command -v {dependency}. Installation might take a minute, as all the available binaries are installed. This process has to be done once whenever installing RNAmotiFold into a new environment, as everything is installed and kept locally.
  3. RNAmotiFold is now ready to use in the virtual environment it was installed in, either through the command line by directly calling RNAmotiFold, RNAmotices, RNAmoSh, or RNAmotiAlign or in your scripts. Simply import RNAmotiFold and you will be able to call RNAmotiFold.rnamotifold, RNAmotiFold.rnamotices, RNAmotiFold.rnamotices_pfc and all the other algorithms directly from your script.

Notes

  • Be sure to check out all the available commandline parameters with RNAmotiFold -h!
  • Calling RNAmotiFold.py without an input will start an interactive session with your set commandline arguments, letting you do individual calculations. Calling it with an input calls your chosen algorithm, does the predictions and returns the output. Interactive sessions are not available through the python API.
  • On the topic of inputs, RNAmotiFold accepts all kinds of inputs, from an RNA sequences as a simple string, to Biopython SeqRecords, to Paths to files or even entire folders. It is also compatible with most of the common file types like .txt, .fa, .sto, and many more.
  • When using RNAmotiFold in a Python script, the return type of the algorithm will be of type AlgorithmOutput which features a method (to_df) to convert your results directly into pandas dataframes! This will always return a list of DataFrames, though it will usually only contain one. The only case where there are multiple DataFrames here is when using any partition function algorithm with the Single Motif Mode. To read more on this refer to our publication: [INSERT RELEASE PUBLICATION HERE]
  • By default, results are piped to stdout and log messages to stderr. You can either pipe them manually with > and 2> or with the RNAmotiFold.py commandline parameters -o [path to result destination file] and --logfile [path to log destination file]
  • Beware RNAmotiAlign has not yet been peer reviewed or published and it is still WIP!

Metadata

Release files for RNAmotiFold 1.0.3

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for RNAmotiFold 1.0.3
File Size Uploaded
rnamotifold-1.0.3.tar.gz 382.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for RNAmotiFold 1.0.3
File Interpreter ABI Platform
rnamotifold-1.0.3-py3-none-any.whl Python 3 none any Details

Total release size: 928.3 kB

Release files / rnamotifold-1.0.3.tar.gz

Download URL rnamotifold-1.0.3.tar.gz
Size 382.9 kB
Tags Source
SHA-256 checksum
How to use checksums
e1014871d099d316ab0bb448ac2fcdfc6c8323f6c0b60dc64f85b284ae223065
BLAKE2b-256 checksum
How to use checksums
9a6b6a46634cce170ae9a29665b8bfe840c13523f5a605501b831c9f52209b08
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.3

Release files / rnamotifold-1.0.3-py3-none-any.whl

Download URL rnamotifold-1.0.3-py3-none-any.whl
Size 545.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
391619993a2522e941d47a3cb0a66ed85a20f4dcd6f3a124798437af21e3a1c9
BLAKE2b-256 checksum
How to use checksums
5351a7105a9a5e22fce6587a11decf2b64bd5a293f6e5a44f3c26db7394fb61f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.3

Release history Release notifications | RSS feed

This release

1.0.3 This release

2 release files

1.0.2

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page