3.2.2. Using PMR with OpenCOR¶
It is a feature of PMR that all data is persistent and permanent. As such, any workspaces created on the main instance of PMR (https://models.physiomeproject.org/) can not be deleted. For the purposes of teaching, we have an alternate instance of PMR (https://teaching.physiomeproject.org/) which is periodically cleared out and synschronised from the main instance. Using the teaching instance allows you to play around without the worry of things being permanent.
- Register for a user account on the teaching instance of PMR.
In order to make use of the teaching instance of PMR, you must first have an account for that instance of the repository. For teaching purposes it is best to register a new account. This can be done by first opening this link in your browser: https://teaching.physiomeproject.org. Then click the Log in button on (shown in Fig. 3.26) then the registration form link.
After filling in the names and email fields and clicking Register you will receive an email inviting you to confirm and set a password. Once that is completed you can then log in. Clicking on My Workspaces will take you to a listing of all your workspaces and provides access to the the Workspace creation form.
- Create a new workspace, in this example the title ‘Test workspace’ has been used.
18.104.22.168. The PMR Workspaces window¶
A window labelled PMR workspaces is available in OpenCOR (see Fig. 3.27). If it is not currently visible it can be selected via (or perhaps the Ctrl-space shortcut).
- Set preferences.
Clicking the preferences button (Fig. 3.27) presents a Preferences dialog box with three settings: PMR instance, Name and Email. For the current purpose choose https://teaching.physiomeproject.org for the first and enter your name and email. These are used to identify you as the author of changes you submit back to the repository (view an example history).
- Log into PMR from OpenCOR.
Before you can view private information or submit changes to PMR you must first log in to PMR from OpenCOR and grant OpenCOR permission to use your account. You accomplish this by clicking on the top right button in the PMR Workspaces window and then logging in with your new user name and password (created in step 1). Then grant access for OpenCOR to gain access to your PMR workspaces. The PMR workspaces window will then show all your workspaces, which should currently consist of the new workspace created in step 2. Note that using the same top right button you can log off - and when you next authenticate you will again be asked to grant access but this time without needing to login with your password.
Right clicking on the workspace name brings up a list of options for that workspace, the first being to view the workspace within PMR (in the web browser). Another option allows you to make a local copy of a workspace on your local disk - this will create a copy of the workspace on your local computer in which you are able to make changes.
- Make a local copy of your test workspace
Using theoption from the right-click menu on the workspace you created in step 2, clone the workspace to your PC. When doing this you will need to provide the folder in which you want to store the workspace contents - make sure you remember where this folder is!
- Save a CellML model to your workspace.
A CellML file opened in OpenCOR (choose any model you have access to) can be saved (PMR Workspaces window. Note that the file appears under the workspace with a red patch on the logo indicating the the file is not yet flagged to upload. To upload the file to PMR, you need to choose from the right-click menu on the workspace folder. This will ask you to provide a description of the change you would like to submit to PMR, and display all the differences you will be synchronising. When you now click the OK button, the changes will actually be submitted to PMR and you will see the file appear on the refreshed browser window. The file icon in the PMR Workspaces window will be shown without the red or green patch. Fig. 3.28 shows two CellML files that have been uploaded to PMR.) to the folder you created for the cloned workspace. Once you have saved a model you will see the file appear under the workspace’s folder in the