All Projects → nennigb → amc2moodle

nennigb / amc2moodle

Licence: GPL-3.0 license
amc2moodle, is an automatic tool to convert multiple choice quiz between auto-muliple-choice LaTeX format and moodle XML format.

Programming Languages

python
139335 projects - #7 most used programming language
TeX
3793 projects
XSLT
1337 projects

Projects that are alternatives of or similar to amc2moodle

moodle-tool pluginskel
Generator of Moodle plugins skeletons
Stars: ✭ 35 (+150%)
Mutual labels:  moodle
moodle-local mailtest
Moodle MailTest allows administrators to test Moodle's email system. A trace of the SMTP dialogue will be displayed if the email message cannot be sent for any reason.
Stars: ✭ 19 (+35.71%)
Mutual labels:  moodle
Aula Global UC3M
A python client to download UC3M Aula Global files and contents from courses
Stars: ✭ 15 (+7.14%)
Mutual labels:  moodle
Moodle-Hacking
Hack Moodle Exam
Stars: ✭ 43 (+207.14%)
Mutual labels:  moodle
moodle-block xp
A gamification plugin for Moodle allowing students to gain experience points and level up.
Stars: ✭ 138 (+885.71%)
Mutual labels:  moodle
OpenTrivia
Multiplayer quiz game demo using React and Opentdb API
Stars: ✭ 47 (+235.71%)
Mutual labels:  multiple-choice
moodle-theme boost campus
Moodle Boost child theme which is intended to meet the needs of university campuses and adds several features and improvements
Stars: ✭ 35 (+150%)
Mutual labels:  moodle
discord-moodle-bot
Get notified about changes on moodle on you favorite platform!
Stars: ✭ 14 (+0%)
Mutual labels:  moodle
moodle-local staticpage
Moodle plugin which displays static information pages which exist outside any course, imprint or faq pages for example, complete with Moodle navigation and theme
Stars: ✭ 37 (+164.29%)
Mutual labels:  moodle
moodle-tool-guide
A Quick Reference Guide for teachers and educators to use Moodle version 3 and later.
Stars: ✭ 18 (+28.57%)
Mutual labels:  moodle
MoodleScraper
scraping resources from moodle
Stars: ✭ 35 (+150%)
Mutual labels:  moodle
moodle-format onetopic
Course format Onetopic to LMS Moodle
Stars: ✭ 15 (+7.14%)
Mutual labels:  moodle
react-native-moodlemobile
A React Native application developed to work with Moodle.
Stars: ✭ 23 (+64.29%)
Mutual labels:  moodle
moodle-tool objectfs
Object file storage system for Moodle
Stars: ✭ 61 (+335.71%)
Mutual labels:  moodle
SigTools
📆 Sigarra Tools | An extension that makes the information system of the University of Porto slightly better.
Stars: ✭ 35 (+150%)
Mutual labels:  moodle
moodle-tool trigger
Like IFTTT for Moodle: events to trigger external services. https://moodle.org/plugins/tool_trigger
Stars: ✭ 32 (+128.57%)
Mutual labels:  moodle
exams-qa
A Multi-subject High School Examinations Dataset for Cross-lingual and Multilingual Question Answering
Stars: ✭ 25 (+78.57%)
Mutual labels:  multiple-choice
docker-compose-moodle
This project quickly builds a local workspace for Moodle (Apache2, PHP-FPM with XDEBUG y Postgres) using containers for each of its main components. The local workspace is built and managed by Docker Compose
Stars: ✭ 33 (+135.71%)
Mutual labels:  moodle
moodle-mod attendance
Allows an attendance log to be kept in Moodle
Stars: ✭ 63 (+350%)
Mutual labels:  moodle
texmlbus
Texmlbus (Tex to XML BUild System) supports the conversion process of documents written in LaTeX to pdf, html, xhtml or jats.
Stars: ✭ 16 (+14.29%)
Mutual labels:  latexml

amc2moodle

pypi release License: GPL v3 CI-Ubuntu CI-Mac-OS

amc2moodle, is a suite of tools to convert multiple choice questionnaires (MCQ)

The conversion supports equations, tables, figures and standard text formatting. This software is written in python and in XSLT, thus the conversion step is OS independent. It has been tested for moodle 3.x and auto-multiple-choice (v1.0.3-v1.4) and the conversion step is OS independent.

Note that auto-multiple-choice (amc) LaTeX format is very convenient, and can be used for preparing multiple choice questions off-line and avoiding moodle web GUI.

Installation

A Docker image with amc2moodle and its dependencies is available at ghcr.io/nennigb/amc2moodle. Once the docker software is installed, this image allows to use amc2moodle on windows plateforms or to add the resource isolation features on linux or macOS. For more information, see the amc2moodle' docker README. To install amc2moodle as a python package on linux or macOS platform, follow the steps below.

Before installing amc2moodle:

  • install python (version >=3.5)
  • install imageMagick, useful to convert image files (*.eps, *.pdf, ...) into png
    • Ubuntu: sudo apt-get install imagemagick
    • MacOS: brew install imagemagick (see ImageMagick website for more details )
  • install LaTeXML [tested with version 0.8.1] This program does the first step of the conversion into XML
    • Ubuntu: sudo apt-get install latexml
    • see also LaTeXML wiki or install notes that all the dependencies are installed (perl, latex, imagemagick).
  • install xmlindent [optional]. This program can be used to indent well the XML file
    • Ubuntu: sudo apt-get install xmlindent
    • MacOS: not necessary. Script will use xmllint natively available on MacOS.

For MacOS users, most dependencies can be installed with brew but LaTeXML installation can failed for some version. Please see the steps given in the install script workflow.

Install with pip

Run

pip install amc2moodle

pip will download automatically the required files.

or if you have download the sources, run

pip install .

in the root folder (where setup.py is). This will automatically install other dependencies i.e., lxml, and Wand. Alternatively, you can run

pip install -e .

to install it in editable mode, useful if git is used.

Note: for Ubuntu users use pip3 instead of pip for python3.

Uninstallation

Run

pip uninstall amc2moodle

Conversion

The program can be run in a shell terminal, for instance to convert an amc LaTeX file to moodle XML

amc2moodle input_Tex_file.tex -o output_file.xml -c catname

Help and options can be obtained using

amc2moodle -h

Then on moodle, go to the course administration\question bank\import and choose 'moodle XML format' and tick: If your grade are not conform to that you must use: 'Nearest grade if not listed' in import option in the moodle question bank (see below for details). Examples of the amc2moodle possibilities are given at QCM.pdf

If your original exam uses AMC-TXT syntax, you must first convert it to LaTeX before feeding it to amc2moodle. To convert an AMC-TXT file to LaTeX, generate the exam documents with AMC graphical interface as usual. AMC will generate a LaTeX version of your exam called DOC-filtered.tex inside the project directory, which you can pass to amc2moodle.

In the same way, conversion from moodle XML to amc LaTeX file, run

moodle2amc input_XML_file.xml

Help and options can be obtained using

moodle2amc -h

Then the output LaTeX can be edited and included for creating amc exams. Examples of the moodle2amc possibilities are given here.

Troubleshooting

In case of problem, do not hesitate to ask for help on discussions or to create an issues. Both binaries (amc2moodle and moodle2amc) write full log in log files based on the name of the input file (_amc2moodle.log and _amc2moodle.log suffixes are added on these files).

  • 'convert: not authorized..' see ImageMagick policy.xml file see here
  • bugs with tikz-LaTeXML in texlive 2019/2020: please update the following perl modules Parse::RecDescent, XML::LibXML and XML::LibXSLT here with cpan or cpanmin CLI.

Related Project

  • auto-multiple-choice, is a piece of software that can help you creating and managing multiple choice questionnaires (MCQ), with automated marking.
  • TeX2Quiz, is a similar project to translate multiple choice quiz into moodle XML, without connection with AMC.
  • moodle - Generating Moodle quizzes via LaTeX. A package for writing Moodle quizzes in LaTeX. In addition to typesetting the quizzes for proofreading, the package compiles an XML file to be uploaded to a Moodle server.
  • moodle-mod-automultiplechoice - An interface to use AMC within Moodle.
  • flatex - A Python script for "flattening" a nested LaTeX document by pulling in all the \input files. Part of this project has been reused in amc2moodle.
  • pyexams, It allows to eval code inside any jupyter kernel (like Sagemath, sympy, ...) and to export them in the moodle XML format.

How to contribute ?

If you want to contribute to amc2moodle, your are welcomed! Don't hesitate to

  • ask for help or share some tips on discussions
  • report bugs, installation problems on issues
  • propose some enhancements in the code or in documentation through pull requests (PR)
  • create a moodle plugin for import
  • support new kind of questions
  • add support for other language (French and English are present) in AMC command
  • ...

To ensure code homogeneity among contributors, we use a source-code analyzer (e.g. pylint). Before submitting a PR, run the tests suite.

License

This file is part of amc2moodle, a tool to convert automultiplechoice quizzes to moodle questions. amc2moodle is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. amc2moodle is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with amc2moodle. If not, see https://www.gnu.org/licenses/.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].