Changes between Version 1 and Version 2 of DVO_FAQ
- Timestamp:
- Aug 9, 2009, 10:57:50 PM (17 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
DVO_FAQ
v1 v2 1 1 Frequently Asked Questions : DVO 2 3 ==== How do I use the dvo shell, variables, math functions, plotting capabilities etc? ==== 4 5 `dvo` uses the [wiki:Opihi_Shell_Language Opihi Shell Language] (q.v. for the amazing number of things you can do in it). 2 6 3 7 ==== How do I update the list of photcodes ? ==== 4 8 5 Your .ptolemyrc file specifies the location of a PHOTCODE_FILE as well as a CATDIR, usually with something like:9 Your .ptolemyrc file specifies the location of a `PHOTCODE_FILE` as well as a `CATDIR`, usually with something like: 6 10 7 CONFDIR /home/panstarrs/ipp/psconfig/ipp-2.6.lin64/share/ippconfig 11 {{{ 12 CONFDIR /home/panstarrs/ipp/psconfig/ipp-2.6.lin64/share/ippconfig 8 13 PHOTCODE_FILE $CONFDIR/dvo.photcodes 9 14 # location of DVO database tables 10 15 CATDIR /data/ipp003.0/catdir 11 12 If you want to update the photometry codes, you will have to edit that dvo.photcodes file or specify the location of a new one. But if you have already created a DVO catdir, then the photcodes are locked in place. Any dvo programs like addstar or dvo itself will pick up the photcodes from the Photcodes.dat file in your CATDIR, not from the PHOTCODE_FILE. So after updating your PHOTCODE_FILE, you must delete the Photcodes.dat file from your CATDIR. Then when you run something like addstar, a new Photcodes.datfile will be automatically created.16 }}} 17 If you want to update the photometry codes, you will have to edit that `dvo.photcodes` file or specify the location of a new one. But if you have already created a DVO catdir, then the photcodes are locked in place. Any dvo programs like addstar or dvo itself will pick up the photcodes from the `Photcodes.dat` file in your `CATDIR`, not from the `PHOTCODE_FILE`. So after updating your `PHOTCODE_FILE`, you must delete the `Photcodes.dat` file from your `CATDIR`. Then when you run something like addstar, a new `Photcodes.dat` file will be automatically created. 13 18 14 19 ==== addstar is reporting a "bad astrometric solution in header." How do I get around that? ==== 15 20 16 You probably have an astrometric error term that exceeds the allowable range. The parameter ADDSTAR_MAX_CERROR can be specified in your camera's dvo.configfile. Try increasing this parameter. To change it at the command line you can use :21 You probably have an astrometric error term that exceeds the allowable range. The parameter `ADDSTAR_MAX_CERROR` can be specified in your camera's `dvo.config` file. Try increasing this parameter. To change it at the command line you can use : 17 22 23 {{{ 18 24 addstar -D ADDSTAR_MAX_CERROR 5.0 ... 19 25 }}} 20 26 ==== After processing a set of overlapping images, there are too many stars in the catalog. What's wrong? ==== 21 27 22 28 You may need to re-sort the dvo catalog. In the normal camera stage processing, each new photometry file is added to the database without any sorting of detected objects (because this is a time-consuming process). Use the following to sort your overlapping catalogs and coordinate multiple occurrences of the same object: 23 29 30 {{{ 24 31 addstar -resort -D CATDIR mycatdir 25 32 }}} 26 33 To specify the radius (in arcseconds) for determining a match, use 27 34 35 {{{ 28 36 addstar -resort -D CATDIR mycatdir -D RADIUS 1.5 29 37 }}} 30 38 or edit the appropriate dvo.config file for your camera. 31 39 32 40 ==== I've got a perfectly good .smf file, but I can't see any stars. What's wrong? ==== 33 41 34 You might have an error in your .ptolemyrcfile.35 Compare your .ptolemyrc file to the dvo.sitefile from the ipp installation you are using.42 You might have an error in your `.ptolemyrc` file. 43 Compare your `.ptolemyrc` file to the `dvo.site` file from the ipp installation you are using. 36 44 37 45 38 46 ==== How do I set up my .ptolemyrc file? ==== 39 47 40 Here is an example .ptolemyrcthat functions with GPC1 data as of ipp-2.6 :48 Here is an example `.ptolemyrc` that functions with GPC1 data as of ipp-2.6 : 41 49 42 <pre> 50 {{{ 43 51 CONFDIR /home/panstarrs/ipp/psconfig/ipp-2.6-bills.lin64/share/ippconfig 44 52 CAMERA default … … 76 84 input $CONFDIR/$CAMERA/dvo.config 77 85 78 </pre> 86 }}} 79 87 80 88 81 89 ==== How can I access info from the mysql database tables within DVO? ==== 82 Use <code>dbconnect</code> to connect to the database and <code>dbselect</code>to collect the data.90 Use `dbconnect` to connect to the database and `dbselect` to collect the data. 83 91 84 <pre> 92 {{{ 85 93 dvo: dbconnect 86 94 USAGE: dbconnect (hostname) (username) (database) … … 88 96 dvo: dbselect 89 97 USAGE: dbselect (fields) from (table) [where] 90 </pre> 98 }}} 91 99 92 100 Here is an example using the '''gpc1''' database that extracts some vectors from the MD09 chip processing output. 93 101 94 <pre> 102 {{{ 95 103 dvo: dbconnect hostmachine uid gpc1 96 104 dvo: dbselect chipProcessedImfile.class_id,chipProcessedImfile.fwhm_major,chipProcessedImfile.fwhm_minor,chipProcessedImfile.n_stars,chipProcessedImfile.n_astrom,chipProcessedImfile.sigma_ra,chipProcessedImfile.sigma_dec FROM chipProcessedImfile,chipRun,rawExp WHERE chipProcessedImfile.chip_id=chipRun.chip_id AND chipRun.exp_id=rawExp.exp_id AND rawExp.ra >= '5.8' AND rawExp.ra <= '5.9' AND rawExp.decl >= '-0.1' AND rawExp.decl <= '0.1' AND rawExp.exp_time>60 AND chipProcessedImfile.fault=0 AND chipRun.state='full' 97 </pre> 105 }}} 98 106 99 107 100 108 ==== How do I create/manipulate a vector/array of values? ==== 101 Create vectors from scratch with the <code>create</code>function Example:109 Create vectors from scratch with the `create` function Example: 102 110 111 {{{ 103 112 create x 0 100 0.1 104 113 }}} 105 114 creates a vector called x with 100 values spaced in increments of 0.1, starting at 0. 106 115 107 Perform arithmetic, etc. with the <code>set</code>function. Use116 Perform arithmetic, etc. with the `set` function. Use 108 117 118 {{{ 109 119 help set 110 120 }}} 111 121 to see detailed help and examples. 112 122 113 123 ==== How do I make a histogram of a vector or an image? ==== 114 The internal dvo documentation (available via <code>help</code> or <code>?</code>) is a bit confusing for this.124 The internal dvo documentation (available via `help` or `?`) is a bit confusing for this. 115 125 116 <code>histogram</code>computes the histogram of a ''vector'' (a list of numbers).126 `histogram` computes the histogram of a ''vector'' (a list of numbers). 117 127 The usage line for this function should be: 128 {{{ 118 129 USAGE: histogram invec outvec start end [delta] 119 120 <code>imhist</code>computes the histogram of an ''image''130 }}} 131 `imhist` computes the histogram of an ''image'' 121 132 The usage line should read: 133 {{{ 122 134 USAGE: imhist <buffer> <x> <y> [-region sx sy nx ny] [-range min max] [-delta binsize] 123 124 '''Ignore the response you get from <code>help histogram</code>'''135 }}} 136 '''Ignore the response you get from `help histogram`''' 125 137 126 138 ==== How do I make plots of vectors and how do I set the plotting style? ==== 127 Use the <code>plot</code> and <code>style</code>functions. Check out the dvo help pages with:139 Use the `plot` and `style` functions. Check out the dvo help pages with: 128 140 141 {{{ 129 142 help plot 130 143 131 144 help style 132 133 See also <code>lim</code> and <code>box</code>145 }}} 146 See also `lim` and `box` 134 147 135 148 ==== How do I save a plot or image to a printable file? ==== 136 149 All of these ''should'' save the current active Kapa window as a file: 150 {{{ 137 151 png outfile.png 138 152 jpeg outfile.jpeg 139 153 ps outfile.ps 140 141 Presently (as of 080814) only the ps command uses the output filename correctly (png saves to ''kapa.png'' regardless of the provided filename) and the <code>jpeg</code>command doesn't seem to do anything at the moment.154 }}} 155 Presently (as of 080814) only the ps command uses the output filename correctly (png saves to ''kapa.png'' regardless of the provided filename) and the `jpeg` command doesn't seem to do anything at the moment. 142 156 143 157 ==== Why does addstar say "Error in config: can't find RADIUS"? ==== … … 145 159 This error occurs when addstar can't find a dvo.config file referenced via 'input' in your ~/.ptolemyrc like so: 146 160 161 {{{ 147 162 input $CONFDIR/$CAMERA/dvo.config 163 }}} 164 `CONFDIR` is the config directory (typically defined earlier in ~/.ptolemyrc). 148 165 149 <code>CONFDIR</code> is the config directory (typically defined earlier in ~/.ptolemyrc). 166 `CAMERA` is the camera name, either also from ~/.ptolemyrc or given on the addstar command line with `-D CAMERA camname`. 150 167 151 <code>CAMERA</code> is the camera name, either also from ~/.ptolemyrc or given on the addstar command line with <code>-D CAMERA camname</code>. 152 153 All of these are case-sensitive (except perhaps on a Mac), so you need to give $CONFDIR and $CAMERA in exactly the capitalization as the corresponding directories on your disk, and the directory and file need to exist, of course. [http://pan-starrs.ifa.hawaii.edu/bugzilla/show_bug.cgi?id=1100 Bug 1100] asks for a clearer error message. 168 All of these are case-sensitive (except perhaps on a Mac), so you need to give $CONFDIR and $CAMERA in exactly the capitalization as the corresponding directories on your disk, and the directory and file need to exist, of course. Bug #1100 asks for a clearer error message.
