IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 28343


Ignore:
Timestamp:
Jun 15, 2010, 3:27:31 PM (16 years ago)
Author:
Paul Price
Message:

Adding database tables and tools for (re-)photometry of diffs.

Location:
trunk
Files:
9 added
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/dbconfig/changes.txt

    r28294 r28343  
    17571757
    17581758ALTER TABLE pstampRequest ADD COLUMN timestamp TIMESTAMP AFTER outdir;
     1759
     1760
     1761-- Tables to support (re-)photometry of a diff
     1762CREATE TABLE diffPhotRun (
     1763    diff_phot_id BIGINT AUTO_INCREMENT, -- Identifier for diffPhotRun
     1764    diff_id BIGINT NOT NULL,            -- Identifier for diffRun
     1765    state VARCHAR(64) NOT NULL,         -- State of run
     1766    workdir VARCHAR(255) NOT NULL, -- working directory
     1767    label VARCHAR(64),             -- processing label
     1768    data_group VARCHAR(64),        -- group for data
     1769    reduction VARCHAR(64),         -- reduction class (for altering recipe)
     1770    registered TIMESTAMP DEFAULT CURRENT_TIMESTAMP, -- time run was registered
     1771    note VARCHAR(255),             -- note
     1772    PRIMARY KEY(diff_phot_id),
     1773    KEY(diff_id),
     1774    KEY(state),
     1775    KEY(label),
     1776    KEY(data_group),
     1777    FOREIGN KEY(diff_id) REFERENCES diffRun(diff_id)
     1778) ENGINE=innodb DEFAULT CHARSET=latin1;
     1779CREATE TABLE diffPhotSkyfile (
     1780    diff_phot_id BIGINT AUTO_INCREMENT, -- Identifier for diffPhotRun
     1781    skycell_id VARCHAR(64) NOT NULL,            -- Skycell identifier
     1782    path_base VARCHAR(255) NOT NULL, -- Base of path for output
     1783    dtime_script FLOAT,              -- elapsed time for script
     1784    hostname VARCHAR(64) NOT NULL,   -- host that executed script
     1785    fault SMALLINT NOT NULL,         -- fault code
     1786    quality SMALLINT NOT NULL,       -- bad quality flag
     1787    software_ver VARCHAR(16),                       -- software version for run
     1788    PRIMARY KEY(diff_phot_id, skycell_id),
     1789    KEY(fault),
     1790    KEY(quality),
     1791    FOREIGN KEY(diff_phot_id) REFERENCES diffPhotRun(diff_phot_id)
     1792) ENGINE=innodb DEFAULT CHARSET=latin1;
  • trunk/dbconfig/ipp.m4

    r28181 r28343  
    3333include(receive.md)
    3434include(publish.md)
     35include(diffphot.md)
  • trunk/ippTools/share/Makefile.am

    r28339 r28343  
    325325     warptool_towarped.sql \
    326326     warptool_updateskyfile.sql \
    327      warptool_warped.sql
     327     warptool_warped.sql \
     328        diffphottool_definerun.sql \
     329        diffphottool_input.sql \
     330        diffphottool_pending.sql \
     331        diffphottool_advance.sql \
     332        diffphottool_revert.sql
  • trunk/ippTools/share/pxadmin_create_tables.sql

    r28294 r28343  
    994994        tess_id VARCHAR(64),
    995995        filter VARCHAR(64),
    996         software_ver VARCHAR(16),
     996        software_ver VARCHAR(16),
    997997        note VARCHAR(255),
    998998        PRIMARY KEY(stack_id),
     
    10421042        quality SMALLINT NOT NULL DEFAULT 0,
    10431043        fault SMALLINT,
    1044         software_ver VARCHAR(16),
     1044        software_ver VARCHAR(16),
    10451045        PRIMARY KEY(stack_id),
    10461046        KEY(dtime_stack),
     
    10651065        exposure TINYINT DEFAULT 0,
    10661066        magicked BIGINT,
    1067         software_ver VARCHAR(16),
     1067        software_ver VARCHAR(16),
    10681068        maskfrac_npix FLOAT,
    10691069        maskfrac_static FLOAT,
     
    11341134        fault SMALLINT,
    11351135        magicked BIGINT,
    1136         software_ver VARCHAR(16),
    1137         maskfrac_npix INT,
    1138         maskfrac_static FLOAT,
    1139         maskfrac_dynamic FLOAT,
    1140         maskfrac_magic FLOAT,
     1136        software_ver VARCHAR(16),
     1137        maskfrac_npix INT,
     1138        maskfrac_static FLOAT,
     1139        maskfrac_dynamic FLOAT,
     1140        maskfrac_magic FLOAT,
    11411141        maskfrac_advisory FLOAT,
    11421142        PRIMARY KEY(diff_id, skycell_id),
     
    16781678) ENGINE=innodb DEFAULT CHARSET=latin1;
    16791679
     1680
     1681-- Tables to support (re-)photometry of a diff
     1682
     1683CREATE TABLE diffPhotRun (
     1684    diff_phot_id BIGINT AUTO_INCREMENT, -- Identifier for diffPhotRun
     1685    diff_id BIGINT NOT NULL,            -- Identifier for diffRun
     1686    state VARCHAR(64) NOT NULL,         -- State of run
     1687    workdir VARCHAR(255) NOT NULL, -- working directory
     1688    label VARCHAR(64),             -- processing label
     1689    data_group VARCHAR(64),        -- group for data
     1690    reduction VARCHAR(64),         -- reduction class (for altering recipe)
     1691    registered TIMESTAMP DEFAULT CURRENT_TIMESTAMP, -- time run was registered
     1692    note VARCHAR(255),             -- note
     1693    PRIMARY KEY(diff_phot_id),
     1694    KEY(diff_id),
     1695    KEY(state),
     1696    KEY(label),
     1697    KEY(data_group),
     1698    FOREIGN KEY(diff_id) REFERENCES diffRun(diff_id)
     1699) ENGINE=innodb DEFAULT CHARSET=latin1;
     1700
     1701CREATE TABLE diffPhotSkyfile (
     1702    diff_phot_id BIGINT AUTO_INCREMENT, -- Identifier for diffPhotRun
     1703    skycell_id VARCHAR(64) NOT NULL,            -- Skycell identifier
     1704    path_base VARCHAR(255) NOT NULL, -- Base of path for output
     1705    dtime_script FLOAT,              -- elapsed time for script
     1706    hostname VARCHAR(64) NOT NULL,   -- host that executed script
     1707    fault SMALLINT NOT NULL,         -- fault code
     1708    quality SMALLINT NOT NULL,       -- bad quality flag
     1709    software_ver VARCHAR(16),                       -- software version
     1710    PRIMARY KEY(diff_phot_id, skycell_id),
     1711    KEY(state),
     1712    KEY(fault),
     1713    KEY(quality),
     1714    FOREIGN KEY(diff_phot_id) REFERENCES diffPhotRun(diff_phot_id)
     1715) ENGINE=innodb DEFAULT CHARSET=latin1;
     1716
    16801717-- This comment line is here to avoid empty query error.
    16811718-- Another way to avoid that problem is to omit the semicolon above but I think that is untidy.
  • trunk/ippTools/src

    • Property svn:ignore
      •  

        old new  
        3939warptool
        4040staticskytool
         41
         42diffphottool
  • trunk/ippTools/src/Makefile.am

    r28091 r28343  
    2525        warptool \
    2626        receivetool \
    27         pubtool
     27        pubtool \
     28        diffphottool
    2829
    2930pkginclude_HEADERS = \
     
    6970        staticskytool.h \
    7071        warptool.h \
    71         pubtool.h
     72        pubtool.h \
     73        diffphottool.h
    7274
    7375lib_LTLIBRARIES = libpxtools.la
     
    264266    pubtoolConfig.c
    265267
     268diffphottool_CFLAGS = $(PSLIB_CFLAGS) $(PSMODULES_CFLAGS) $(IPPDB_CFLAGS)
     269diffphottool_LDADD = $(PSLIB_LIBS) $(PSMODULES_LIBS) $(IPPDB_LIBS) libpxtools.la
     270diffphottool_SOURCES = \
     271    diffphottool.c \
     272    diffphottoolConfig.c
     273
    266274clean-local:
    267275        -rm -f TAGS
Note: See TracChangeset for help on using the changeset viewer.