Media Server 25.4
Media Server Help

# Upgrade Trained Models (Caffe to Torch)

Media Server 25.3 uses the Torch machine learning library. Earlier versions of Media Server used Caffe. This topic describes how to upgrade your trained models so that they are compatible with Media Server 25.3.

The database upgrade processes the following data:

- Trained image classifiers
- Trained object class recognizers
- Image embedding encoders
- Face recognition databases that you have fine-tuned

If you do not use any of these features, no additional upgrade steps are necessary and you can start Media Server 25.3 with your Media Server 25.2 database.

IMPORTANT: OpenText recommends that you make a backup of your database before beginning the upgrade.

IMPORTANT: Before you start, ensure your database has been upgraded to the latest schema version. If you are upgrading from Media Server 23.2 or earlier, see the topic Upgrade the Database Schema for instructions about how to upgrade to the latest schema.

To upgrade trained models for compatibility with Media Server 25.3

1. Stop all of your Media Server instances, to ensure that there are no connections to the database.

2. Unzip Media Server 25.3 to your chosen installation directory.

3. If you are using an internal database, copy your `mediaserver.db` database file into the new installation.

4. Copy your Media Server configuration file into the new installation. The configuration file must contain the configuration for the database that you want to upgrade. For example, if you are using an external PostgreSQL database, the Media Server configuration file must include the connection string.

5. Create a suitable Python environment.

   The upgrade steps have been tested with Python 3.12 so OpenText recommends using that version. OpenText recommends creating a Python virtual environment and installing the necessary dependencies by running the following commands.

   1. In a new directory, initialize a new Python virtual environment:

          python -m venv .

   2. Activate the virtual environment:

      Windows

          Scripts\activate.bat

      Linux

          ./bin/activate

   3. Install the necessary dependencies:

          pip install torch==2.5.1 torchvision==0.20.1 torchaudio==2.5.1 --index-url https://download.pytorch.org/whl/cpu

          cd MediaServerInstallFolder

      where MediaServerInstallFolder is the installation folder for the new Media Server 25.3 deployment.

          pip install -r databaseconversion/requirements.txt

6. Perform the conversion:

       cd MediaServerInstallFolder

   where MediaServerInstallFolder is the installation folder for the new Media Server 25.3 deployment.

       python databaseconversion/updateMediaserverDatabase.py -c mediaserver.cfg

   where `mediaserver.cfg` is the path to the Media Server configuration file that contains the configuration parameters necessary to connect to your database.

7. Start Media Server 25.3 and verify that your training data is present.

Copyright 2025 Open Text
Version 25.4 | Last updated October 2025

Send documentation feedback

Close

Send documentation feedback

To send feedback using your default email client, open an email window.

Otherwise, send your feedback and the information below to MFI-swpdl.idoldocsfeedback@opentext.com.

We appreciate your feedback!

Product: Knowledge Discovery Media Server 25.4

Topic Title: Upgrade Trained Models (Caffe to Torch)