Fix coordinates in hgvs annotations.
[lightning.git] / plot.go
diff --git a/plot.go b/plot.go
index 9723c91c88625ec99830f135aafea8ffdaae12a0..0367b1241a76291b192723e01dca9f72fd6335b6 100644 (file)
--- a/plot.go
+++ b/plot.go
@@ -1,4 +1,8 @@
-package main
+// Copyright (C) The Lightning Authors. All rights reserved.
+//
+// SPDX-License-Identifier: AGPL-3.0
+
+package lightning
 
 import (
        "flag"
@@ -24,6 +28,7 @@ func (cmd *pythonPlot) RunCommand(prog string, args []string, stdin io.Reader, s
        inputFilename := flags.String("i", "-", "input `file`")
        sampleCSVFilename := flags.String("labels-csv", "", "use first two columns of `labels.csv` as id->color mapping")
        sampleFastaDirname := flags.String("sample-fasta-dir", "", "`directory` containing fasta input files")
+       priority := flags.Int("priority", 500, "container request priority")
        err = flags.Parse(args)
        if err == flag.ErrHelp {
                err = nil
@@ -36,8 +41,9 @@ func (cmd *pythonPlot) RunCommand(prog string, args []string, stdin io.Reader, s
                Name:        "lightning plot",
                Client:      arvados.NewClientFromEnv(),
                ProjectUUID: *projectUUID,
-               RAM:         1 << 30,
+               RAM:         4 << 30,
                VCPUs:       1,
+               Priority:    *priority,
                Mounts: map[string]map[string]interface{}{
                        "/plot.py": map[string]interface{}{
                                "kind":    "text",
@@ -114,7 +120,10 @@ if sys.argv[2]:
         'PJL': 'blueviolet',
     }
     for fnm in sorted(labels.keys()):
-        colors.append(labelcolors[labels[fnm]])
+        if labels[fnm] in labelcolors:
+            colors.append(labelcolors[labels[fnm]])
+        else:
+            colors.append('black')
 
 from matplotlib.figure import Figure
 from matplotlib.patches import Polygon