# 28.January.2014 Liz Brooks
# script to populate the database with Datasource and Sensor information 
# from the NPS plant phenology camera.

import populate
debug = True


if __name__ == '__main__':
    if debug: print "Starting Phenocam setup script..."

    # create Weather Underground data source ------------------------------
    if debug: print "Creating Datasource..."
    mysource = populate.add_datasource( datasource_id = "Plant Phenology Camera",
                                        owner = "NPS - National Parks Service",
                                        access_info="manual",
                                        symbol="PP"
                                    )

    # create Sensors from this datasource ---------------------------------
    if debug: print "Creating Sensors..."
    s1 = populate.add_sensor( sensor_id = "pp_camera",
                     source = mysource,
                     short_name="Plant Phenology",
                     data_type = "jpg",
                     is_headliner = False,
                     kind = "hide",
                 )

    if debug: print "Finished Phenocam setup script."
Пример #2
0
        desc="Beacon Buoy - Boston Harbor, Thompson Island Mooring Field - Dorchester Bay",
        owner = "cesn - Coastal Environmental Sensing Networks",
        latitude=42.3196,
        longitude=-71.0219,
        access_info="deviceID='2232583' station_type='cdombuoy'",
        symbol="BB"
    )

    # create Sensors from this datasource ---------------------------------
    if debug: print "Creating Sensors..."
    s1 = populate.add_sensor( sensor_id = "buoy5_Salinity",
                     source = mysource,
                     short_name="Salinity",
                     data_type = "float",
                     is_number = True,
                     units_long = "practical salinity units",
                     units_short = "PSU",
                     is_headliner = False,
                     kind = "hydrological",
                     line_color = populate.hex_color('orange'),
                 )
    s2 = populate.add_sensor( sensor_id = "buoy5_CDOM",
                     source = mysource,
                     short_name="CDOM",
                     data_type = "float",
                     is_number = True,
                     units_long = "QSU",
                     units_short = "QSU",
                     kind = "hydrological",
                     line_color = populate.hex_color('brown'),
                 )
# 28.January.2014 Liz Brooks
# script to populate the database with Datasource and Sensor information
# from the NPS plant phenology camera.

import populate
debug = True

if __name__ == '__main__':
    if debug: print "Starting Phenocam setup script..."

    # create Weather Underground data source ------------------------------
    if debug: print "Creating Datasource..."
    mysource = populate.add_datasource(datasource_id="Plant Phenology Camera",
                                       owner="NPS - National Parks Service",
                                       access_info="manual",
                                       symbol="PP")

    # create Sensors from this datasource ---------------------------------
    if debug: print "Creating Sensors..."
    s1 = populate.add_sensor(
        sensor_id="pp_camera",
        source=mysource,
        short_name="Plant Phenology",
        data_type="jpg",
        is_headliner=False,
        kind="hide",
    )

    if debug: print "Finished Phenocam setup script."
Пример #4
0
# script to populate the database with DataSource and Sensor information
# from Cameras.

import populate
debug = True

if __name__ == '__main__':
    if debug: print "Starting Song Stream setup script..."

    # create Salt Pond data source ------------------------------
    if debug: print "Creating Datasource..."
    mysource = populate.add_datasource(
        datasource_id="Song Stream Audio",
        desc=
        "Wildlife Accoustics Song Stream Remote Access Audio Recording Station",
        owner="Wildlife Accoustics",
        access_info=
        "https://songstream.wildlifeacoustics.com/ account=THOMPSON_ISLAND user=STUDENT password=SS_PASSWORD",
        symbol="SS")

    # create Sensors from this datasource ---------------------------------
    if debug: print "Creating Sensors..."
    s1 = populate.add_sensor(
        sensor_id="ss_wav",
        source=mysource,
        short_name="Bird Song",
        data_type="wav",
        is_headliner=True,
    )
    if debug: print "Finished Song Stream setup script!"
                               owner = "Weather Underground",
                               latitude=42.317165,
                               longitude=-71.007622,
                               elevation=100.0,
                               access_info="stationID='KMABOSTO32' APIkey=WU_API_KEY",
                               symbol="WU"
                           )

    # create Sensors from this datasource ---------------------------------
    if debug: print "Creating Sensors..."
    s1 = populate.add_sensor( sensor_id = "wu_ti_temp_c",
                     source = mysource,
                     short_name="Air Temperature",
                     data_type = "float",
                     is_number = True,
                     units_long = "degrees Celsius",
                     units_short = "°C",
                     is_headliner = True,
                     kind = "meteorological",
                     line_color = populate.hex_color('red'),
                 )
    s2 = populate.add_sensor( sensor_id = "wu_ti_relative_humidity",
                     source = mysource,
                     short_name="Relative Humidity",
                     data_type = "float",
                     is_number = True,
                     units_long = "percent",
                     units_short = "%",
                     kind = "meteorological",
                     is_headliner = True,
                     line_color = populate.hex_color('light_green'),
Пример #6
0
        datasource_id="Weather Underground Thompson Island",
        owner="Weather Underground",
        latitude=42.317165,
        longitude=-71.007622,
        elevation=100.0,
        access_info="stationID='KMABOSTO32' APIkey=WU_API_KEY",
        symbol="WU")

    # create Sensors from this datasource ---------------------------------
    if debug: print "Creating Sensors..."
    s1 = populate.add_sensor(
        sensor_id="wu_ti_temp_c",
        source=mysource,
        short_name="Air Temperature",
        data_type="float",
        is_number=True,
        units_long="degrees Celsius",
        units_short="°C",
        is_headliner=True,
        kind="meteorological",
        line_color=populate.hex_color('red'),
    )
    s2 = populate.add_sensor(
        sensor_id="wu_ti_relative_humidity",
        source=mysource,
        short_name="Relative Humidity",
        data_type="float",
        is_number=True,
        units_long="percent",
        units_short="%",
        kind="meteorological",
        is_headliner=True,
# 26.January.2014 Liz Brooks
# script to populate the database with DataSource and Sensor information 
# from Cameras.

import populate
debug = True


if __name__ == '__main__':
    if debug: print "Starting Song Stream setup script..."

    # create Salt Pond data source ------------------------------
    if debug: print "Creating Datasource..."
    mysource = populate.add_datasource( datasource_id = "Song Stream Audio",
                               desc="Wildlife Accoustics Song Stream Remote Access Audio Recording Station",
                               owner = "Wildlife Accoustics",
                               access_info="https://songstream.wildlifeacoustics.com/ account=THOMPSON_ISLAND user=STUDENT password=SS_PASSWORD",
                               symbol="SS"
                           )

    # create Sensors from this datasource ---------------------------------
    if debug: print "Creating Sensors..."
    s1 = populate.add_sensor( sensor_id = "ss_wav",
                     source = mysource,
                     short_name="Bird Song",
                     data_type = "wav",
                     is_headliner = True,
                 )
    if debug: print "Finished Song Stream setup script!"
    if debug: print "Creating Datasource..."
    mysource = populate.add_datasource(
        datasource_id="Thompson Island Salt Pond",
        desc="Thompson Island Salt Pond hydrologic sensor",
        owner="cesn - Coastal Environmental Sensing Networks",
        access_info="https://datagarrison.com/ user=thompson pass=SP_PASSWORD",
        symbol="SP")

    # create Sensors from this datasource ---------------------------------
    if debug: print "Creating Sensors..."
    s1 = populate.add_sensor(
        sensor_id="sp_air_pressure",
        source=mysource,
        short_name="Air Pressure",
        data_type="float",
        is_number=True,
        units_long="decibars",
        units_short="dbar",
        kind="meteorological",
        line_color=populate.hex_color('gray'),
    )
    s2 = populate.add_sensor(
        sensor_id="sp_water_temp",
        source=mysource,
        short_name="Water Temperature",
        data_type="float",
        is_number=True,
        units_long="degrees Celsius",
        units_short="°C",
        kind="hydrological",
        line_color=populate.hex_color('purple'),
    mysource = populate.add_datasource( datasource_id = "Nortek Station Thompson Island",
                               owner = "Nortek",
                               latitude=42.3192,
                               longitude=-71.0104,
                               access_info="stationNo=6016 stationID=e22a07ba note .xls file is html",
                               symbol="NOR"
                           )

    # create Sensors from this datasource ---------------------------------
    if debug: print "Creating Sensors..."
    s1 = populate.add_sensor( sensor_id = "nor_Wind_speed_avg",
                     source = mysource,
                     short_name="Wind Speed",
                     data_type = "float",
                     is_number = True,
                     units_long = "meters per second",
                     units_short = "m/s",
                     is_headliner = True,
                     kind = "meteorological",
                     line_color = populate.hex_color('dark_blue'),
                 )
    s2 = populate.add_sensor( sensor_id = "nor_Wind_speed_max",
                     source = mysource,
                     short_name="Wind Gust",
                     data_type = "float",
                     is_number = True,
                     units_long = "meters per second",
                     units_short = "m/s",
                     is_headliner = True,
                     kind = "meteorological",
                     line_color = populate.hex_color('blue'),
    # create Salt Pond data source ------------------------------
    if debug: print "Creating Datasource..."
    mysource = populate.add_datasource( datasource_id = "Thompson Island Salt Pond",
                               desc="Thompson Island Salt Pond hydrologic sensor",
                               owner = "cesn - Coastal Environmental Sensing Networks",
                               access_info="https://datagarrison.com/ user=thompson pass=SP_PASSWORD",
                               symbol="SP"
                           )

    # create Sensors from this datasource ---------------------------------
    if debug: print "Creating Sensors..."
    s1 = populate.add_sensor( sensor_id = "sp_air_pressure",
                     source = mysource,
                     short_name="Air Pressure",
                     data_type = "float",
                     is_number = True,
                     units_long = "decibars",
                     units_short = "dbar",
                     kind = "meteorological",
                     line_color = populate.hex_color('gray'),
                 )
    s2 = populate.add_sensor( sensor_id = "sp_water_temp",
                     source = mysource,
                     short_name="Water Temperature",
                     data_type = "float",
                     is_number = True,
                     units_long = "degrees Celsius",
                     units_short = "°C",
                     kind = "hydrological",
                     line_color = populate.hex_color('purple'),
                 )
    s3 = populate.add_sensor( sensor_id = "sp_salinity",