PatternQuery:Command Line

From WebChem Wiki
Jump to: navigation, search

This is help for version 1.0.15.4.22 or newer. The help text for other versions can be viewed using the --help command when running the application.

Technical details

Where to find PatternQuery

PatternQuery is freely available online since May 2014 at http://ncbr.muni.cz/PatternQuery. There is no login requirement for accessing PatternQuery.

What you need in order to run PatternQuery

  • Up to date internet browser with WebGL support.
  • JavaScript enabled.

Check if your browser is WebGL and Javascript compliant.

Note that you can run PatternQuery and download the results even if your browser doesn't support WebGL. WebGL is only necessary for the 3D visualization functionality.

In some older browsers, the interactive user guide which provides help for the GUI interface does not work optimally.

Running the Offline Service


Just download the latest release of PatternQuery application. A simple demo is available as well. The service can be executed using the command (latest .NET Framework required):

WebChemistry.Queries.Service.exe workingFolder configuration.json

In Linux (where available) and MacOS, the latest version the Mono Framework (http://mono-project.com/) must be used to run the application:

mono WebChemistry.Queries.Service.exe workingFolder configuration.json

Both of the commands immediately executes a calculation, which produces all the output into the workingFolder. A further description can be found when running the program with the --help option. e.g.

WebChemistry.Queries.Service.exe --help
or
mono WebChemistry.Queries.Service.exe --help

Configuration

The configuration is specified using the JSON format.

Configuration Example

This is the general shape of the JSON input configuration.

{
  "InputFolders": [
    "c:\\TestData\\PDB\\SampleSet1"
  ],
  "Queries": [
    {
      "Id": "NAGs",
      "QueryString": "Residues(\"NAG\")"
    },
    {
      "Id": "MANs",
      "QueryString": "Residues('MAN')"
    }
  ],
  "StatisticsOnly": false,
  "CSAPath": "c:\\data\\csa.dat",
  "MaxParallelism": 8
}

There has to be exactly one configuration file for each validation run. Every value, as well as settings' names, is surrounded in quotation marks (" " or ' '). Backslashes (\) have to be escaped (\\). File system paths can be absolute as well as relative (/ works as well in paths).

Attributes

  • InputFolders [ String[] ]
A list of folders containing the input structures.
A list of queries.
  • StatisticsOnly [ Boolean ]
If `true`, the files with fragments are not exported.
  • CSAPath [ String ]
Optional path to a file with CSA database that allows the CSA() query to work. The file is a CSV file that must contain the columns `PdbID, SiteNumber, ResidueName, ChainId, ResidueNumber, ...`
  • MaxParallelism [ Int32 ], Default value = 8
The maximum number of structures that can be processed simultaneously.

Descriptions

QueryInfo
  • Id [ String ]
A unique identifier of the query.
  • QueryString [ String ]
The query expression.


Output Description

General Structure

  • [WorkingDirectory] - Working directory of the application.
  • result - Contains the result of the computation.
log.txt - Contains the console output of the application.
status.json - Contains general information of the computation (running time, version, etc.).

MotiveQuery Specific Structure

  • result - Folder with computation result
  • query_id - Folder for each query named by its unique id.
  • patterns - Folder with patterns stored in PDB format.
data.json - Information about the result in JSON format.
patterns.csv - Information about the patterns in CSV format.
metadata_summary.csv - Information about the metadata (origin organism, EC number, etc.) in CSV format.
structures.csv - Information about structures that contain the given patterns in CSV format.
structures.csv - Information about all structures that were queried in CSV format.
structures.json - Information about all structures that were queried in JSON format.
summary.json - Summary information (number of found patterns, etc.) about the computation in JSON format.