text:
```@meta
EditURL="https://hirlam.org/trac//wiki//ObservationHowto/Atovs?action=edit"
```

# ATOVS radiances (pre-) processing

## Introduction

The IFS/ARPEGE/AROME data assimilation code uses level 1-c radiances. ATOVS radiances are available through local HRPT (High Rate Picture Transmission) antenna and the EUMETSAT EARS (European Advanced Retransmission Service) EUMETCast broadcasting system. Data received through local antenna need to be pre-processed with the ATOVS and AVHRR Pre-processing Package (AAPP). Radiances are also available trough the GTS, but with longer timelines.

This short description explains how to prepare ATOVS radiances for (operational) data assimilation. Like all radiances, ATOVS data bias is corrected using Variational technique. VarBC coefficients should be updated for each limited area model. The variational bias correction is activated through namelist switches (see below).

## ATOVS radiances

### scr/include.ass
[include.ass](https://hirlam.org/trac/browser/scr/include.ass) should be edited to "switch on" the use of AMSUA (AMSU-A), AMSUB (AMSU-B/MHS):
```bash
export AMSUA_OBS=1             # AMSU-A
export AMSUB_OBS=1             # AMSU-B, MHS
export ATOVS_SOURCE=mars       # local: EUMETCast;
                               # mars: data from MARS
                               # hirlam: hirlam radiance template
```

The default handling of ATOVS (AMSU-A and AMSU-B/MHS) is so that we store/load them in separate ODB bases. The definition of the bases in Harmonie is done in [include.ass](https://hirlam.org/trac/browser/scr/include.ass).
### Loading the ATOVS radiances
### = Data extracted from MARS=
 * Data extracted from MARS (the default setting in the Harmonie) is loaded the following way: * After extraction, all observations, including the radiances, are shuffled per observation type; * In Bator ATOVS data are loaded from the oulan working directory the following way:{{{
        # AMSU-A observations
      elif [ "$base" = amsua] ; then
        # AMSU-A
        if [ "$AMSUA_OBS" -eq 1]; then
          echo "amsua    BUFR     amsua            ${YMD} ${HH}">>refdata
          ln -sf "$WRK"/oulan/amsua ./BUFR.amsua
          cp "${HM_LIB}"/nam/param_bator.cfg.amsua."${ATOVS_SOURCE}" ./param.cfg
        fi
      elif [ "$base" = amsub] ; then
        # AMSU-B
        if [ "$AMSUB_OBS" -eq 1]; then
          echo "amsub    BUFR     amsub            ${YMD} ${HH}">>refdata
          ln -sf "$WRK"/oulan/amsub ./BUFR.amsub
          cp "${HM_LIB}"/nam/param_bator.cfg.amsub."${ATOVS_SOURCE}" ./param.cfg
        fi
```

### = Locally received data=
  * Locally received (usually through the EARS system) data are loaded the from a source or the "observations" directory. Note, it is recommanded to have both AMSU-B and MHS data in one file. Otherwise, it's recommanded to create a single file with them. One can use the command "cat" to do this.  * The example below shows a case when AMSU-B and MHS are stored in different BUFR files:{{{
         # AMSU-A observations
      elif [ "$base" = amsua] ; then
        # AMSU-A
        if [ "$AMSUA_OBS" -eq 1]; then
          echo "amsua    BUFR     amsua            ${YMD} ${HH}">>refdata
          #ln -sf "$WRK"/oulan/amsua ./BUFR.amsua
          ln -sf /scratch/ms/no/sbt/hm_home/RR_CONV/observations/amsua${YMD}${HH} ./BUFR.amsua
          cp "${HM_LIB}"/nam/param_bator.cfg.amsua."${ATOVS_SOURCE}" ./param.cfg
        fi
      elif [ "$base" = amsub] ; then
        # AMSU-B
        if [ "$AMSUB_OBS" -eq 1]; then
          cat /scratch/ms/no/sbt/hm_home/RR_CONV/observations/amsub${YMD}${HH}  /scratch/ms/no/sbt/hm_home/RR_CONV/observations/mhs${YMD}${HH} > "$WRK"/oulan/amsub
          echo "amsub    BUFR     amsub            ${YMD} ${HH}">>refdata
          ln -sf "$WRK"/oulan/amsub ./BUFR.amsub
          cp "${HM_LIB}"/nam/param_bator.cfg.amsub."${ATOVS_SOURCE}" ./param.cfg
        fi
```

### param.cfg
The BUFR template used by ATOVS (AMSU-A, AMSU-B/MHS) data should be defined in the param_bator.cfg.${atovs}.${ATOVS_SOURCE} file used by Bator. Where $atovs (amsua or amsua) and ATOVS_SOURCE as defined above according to the source of the data source. param.cfg files for Bator are in the [nam](https://hirlam.org/trac/browser//trunk/harmonie/nam) namelist directory. The ATOVS param.cfg template should be something like this:
For locally processed AMSU-A:
```bash
BEGIN amsua
1 1 0 14
codage     1  310009
control    1      15  nb de canaux
values     6  001034  Originating sub-centre
values     7  001007  Satellite identifier
values    11  005041  Scan line number
values    12  005043  Field of view number
values    22  005001  Latitude
values    23  006001  Longitude
values    16  004001  Year
values    25  007024  Satellite zenith angle
values    24  007001  Height of station
values    26  005021  Bearing or azimuth
values    27  007025  Solar zenith angle
values    28  005022  Solar azimuth
values    43  012063  Brightness Temperature
values    38  002150  Tovs Channel number
END amsua
```

For AMSU-A from MARS:
```bash
BEGIN amsua
1 1 0 14
codage     1  310008
control    1      15  nb de canaux
values     6  001034  Originating sub-centre
values     7  001007  Satellite identifier
values    11  005041  Scan line number
values    12  005043  Field of view number
values    22  005001  Latitude
values    23  006001  Longitude
values    16  004001  Year
values    25  007024  Satellite zenith angle
values    24  007001  Height of station
values    26  005021  Bearing or azimuth
values    27  007025  Solar zenith angle
values    28  005022  Solar azimuth
values    43  012063  Brightness Temperature
values    38  002150  Tovs Channel number
END amsua
```

For locally processed AMSU-B:
```bash
BEGIN amsub
1 1 0 15
codage     1  310010
control    1       5  nb de canaux
values     6  001034  Originating sub-centre
values     7  001007  Satellite identifier
values    11  005041  Scan line number
values    12  005043  Field of view number
values    22  005001  Latitude
values    23  006001  Longitude
values    16  004001  Year
values     8  002048  Satellite sensor type
values    24  007001  Height of station
values    25  007024  Satellite zenith angle
values    26  005021  Bearing or azimuth
values    27  007025  Solar zenith angle
values    28  005022  Solar azimuth
values    38  002150  Tovs Channel number
values    43  012063  Brightness Temperature
END amsub
```

For AMSU-B from MARS:
```bash
BEGIN amsub
1 1 0 15
codage     1  310008
control    1       5  nb de canaux
values     6  001034  Originating sub-centre
values     7  001007  Satellite identifier
values    11  005041  Scan line number
values    12  005043  Field of view number
values    22  005001  Latitude
values    23  006001  Longitude
values    16  004001  Year
values     8  002048  Satellite sensor type
values    24  007001  Height of station
values    25  007024  Satellite zenith angle
values    26  005021  Bearing or azimuth
values    27  007025  Solar zenith angle
values    28  005022  Solar azimuth
values    38  002150  Tovs Channel number
values    43  012063  Brightness Temperature
END amsub
```

### BATOR namelist and data extraction

Depending on the satellite and channel you may have to add entries to the NADIRS namelist in the Bator script like the following:
```bash
 &NADIRS
   LMFBUFR=.FALSE.,
   TS_AMSUA(206)%t_select%ChannelsList(:) = -1,
   TS_AMSUA(206)%t_select%TabFov(:) = -1,
   TS_AMSUA(206)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUA(207)%t_select%TabFov(:) =  -1,
   TS_AMSUA(207)%t_select%ChannelsList(:) = -1,
   TS_AMSUA(207)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUA(209)%t_select%ChannelsList(:) = -1,
   TS_AMSUA(209)%t_select%TabFov(:) = -1,
   TS_AMSUA(209)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUA(223)%t_select%ChannelsList(:) = -1,
   TS_AMSUA(223)%t_select%TabFov(:) = -1,
   TS_AMSUA(223)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUA(4)%t_select%ChannelsList(:) = -1,
   TS_AMSUA(4)%t_select%TabFov(:) = -1,
   TS_AMSUA(4)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUA(3)%t_select%ChannelsList(:) = -1,
   TS_AMSUA(3)%t_select%TabFov(:) = -1,
   TS_AMSUA(3)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUA(3)%t_select%SclJump = 0,
   TS_AMSUA(784)%t_select%TabFov(:) = -1,
   TS_AMSUA(784)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUB(206)%t_select%TabFov(:) = -1,
   TS_AMSUB(206)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUB(206)%t_select%SclJump = 0,
   TS_AMSUB(206)%t_satsens%ModSensor = -1,
   TS_AMSUB(207)%t_select%TabFov(:) = -1,
   TS_AMSUB(207)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUB(207)%t_select%SclJump = 0,
   TS_AMSUB(207)%t_select%ChannelsList(:) = -1,
   TS_AMSUB(208)%t_select%TabFov(:) = -1,
   TS_AMSUB(208)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUB(208)%t_select%SclJump = 0,
   TS_AMSUB(208)%t_select%ChannelsList(:) = -1,
   TS_AMSUB(209)%t_select%TabFov(:) = -1,
   TS_AMSUB(209)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUB(209)%t_select%SclJump = 0,
   TS_AMSUB(209)%t_satsens%ModSensor = 4,
   TS_AMSUB(209)%t_select%ChannelsList(:) = -1,
   TS_AMSUB(4)%t_select%TabFov(:) = -1,
   TS_AMSUB(4)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUB(4)%t_select%SclJump = 0,
   TS_AMSUB(4)%t_select%ChannelsList(:) = -1,
   TS_AMSUB(3)%t_select%TabFov(:) = -1,
   TS_AMSUB(3)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUB(3)%t_select%SclJump = 0,
   TS_AMSUB(3)%t_satsens%ModSensor = 15,
   TS_AMSUB(223)%t_select%TabFov(:) = -1,
   TS_AMSUB(223)%t_select%TabFovInterlace(:) = -1,
   TS_AMSUB(223)%t_select%SclJump = 0,
   TS_AMSUB(223)%t_select%ChannelsList(:) = -1,
```

All the "-1" mean that we extract all available data we found. No restriction on the channels nor fields of view (FOV), nor on scanning lines (through "TS_AMSUB(???)%t_select%SclJump = 0,"). The default choices are defined in the routine called [src/odb/pandor/module/bator_init_mod.F90](https://hirlam.org/trac/browser/Harmonie/src/odb/pandor/module/bator_init_mod.F90). Note that although the NOAA-18 was embarked with MHS instrument, somehow our system treat the NOAA-18 MHS as AMSU-B (implementation decision) "TS_AMSUB(209)%t_satsens%ModSensor = 4," is changing the instrument characteristics in our system, while for Metop-A MHS is defined through "TS_AMSUB(3)%t_satsens%ModSensor = 15,".

## Variational bias correction and screening

The variational technique is used to correct the bias for radiance data in Harmonie. Default choice of predictors used to correct bias for different channels of different instruments is defined in [varbc_rad.F90](https://hirlam.org/trac/browser//trunk/harmonie/src/arpifs/module/varbc_rad.F90) as the example taken for AMSU-B below:

```bash
DO ic = 2, 5
  SELECT case (ic)
  case (2)
    yconfig(msensor_AMSUB, ic)%nparam = 4
    yconfig(msensor_AMSUB, ic)%npredcs(1:4) = (/0,8,9,10/)
  case (3:5)
    yconfig(msensor_AMSUB, ic)%nparam = 8
    yconfig(msensor_AMSUB, ic)%npredcs(1:8) = (/0,1,2,5,6,8,9,10/)
  END SELECT
ENDDO
```

The choice for predictors for VarBC in Harmonie is given through namelist of the screening and minimisation in "nam/harmonie_namelist.pm" as follows. The update concerns the choice of predictors for each channel of the used instruments and also the "**nbg**" (nbg_AMSUA, nbg_AMSUB, nbg_MHS, ...) definition for each instruments. Note that the "NBG" defines the "speed of the  adaptivity" of the varBC. High value have slowing, while low value have speeding effect:

```bash
 NAMVARBC=>{
 },
 NAMVARBC_RAD=>{
 'LBC_RAD' => '.TRUE.,',
 'yconfig(3,5)%nparam' => '10',
 'yconfig(3,5)%npredcs(1:10)' => '0,1,2,8,9,10,15,16,17,18',
 'yconfig(3,6)%nparam' => '5',
 'yconfig(3,6)%npredcs(1:5)' => '0,1,8,9,10',
 'yconfig(3,7)%nparam' => '5',
 'yconfig(3,7)%npredcs(1:5)' => '0,1,8,9,10',
 'yconfig(3,8)%nparam' => '5',
 'yconfig(3,8)%npredcs(1:5)' => '0,1,8,9,10',
 'yconfig(3,9)%nparam' => '5',
 'yconfig(3,9)%npredcs(1:5)' => '0,1,8,9,10',
 'yconfig(3,10)%nparam' => '5',
 'yconfig(3,10)%npredcs(1:5)' => '0,1,8,9,10',
 'yconfig(4,2)%nparam' => '4',
 'yconfig(4,2)%npredcs(1:4)' => '0,8,9,10',
 'yconfig(4,3)%nparam' => '5',
 'yconfig(4,3)%npredcs(1:5)' => '0,1,8,9,10',
 'yconfig(4,4)%nparam' => '5',
 'yconfig(4,4)%npredcs(1:5)' => '0,1,8,9,10',
 'yconfig(4,5)%nparam' => '5',
 'yconfig(4,5)%npredcs(1:5)' => '0,1,8,9,10',
 'yconfig(15,2)%nparam' => '4',
 'yconfig(15,2)%npredcs(1:4)' => '0,8,9,10',
 'yconfig(15,3)%nparam' => '5',
 'yconfig(15,3)%npredcs(1:5)' => '0,1,8,9,10',
 'yconfig(15,4)%nparam' => '5',
 'yconfig(15,4)%npredcs(1:5)' => '0,1,8,9,10',
 'yconfig(15,5)%nparam' => '5',
 'yconfig(15,5)%npredcs(1:5)' => '0,1,8,9,10',
 'nbg_AMSUA' => '2000',
 'nbg_AMSUB' => '2000',
 'nbg_MHS' => '2000'
```

 * Satellite identifiers are available here: [https://software.ecmwf.int/wiki/display/ECC/WMO%3D27+code-flag+table]

## Source code
The reading of BUFR ATOVS (AMSU-A and AMSU-B/MHS) is taken care of by the [and [source:amsub](https://hirlam.org/trac/browser/amsua]) subroutines in [src/odb/pandor/module/bator_decodbufr_mod.F90](https://hirlam.org/trac/browser/Harmonie/src/odb/pandor/module/bator_decodbufr_mod.F90). These subroutines read the above parameters defined in the param.cfg file (see above):

Default values for VarBC are defined in [src/arpifs/module/varbc_rad.F90](https://hirlam.org/trac/browser/Harmonie/src/arpifs/module/varbc_rad.F90).

The defined varBC predictors are computed in [src/arpifs/module/varbc_pred.F90](https://hirlam.org/trac/browser/Harmonie/src/arpifs/module/varbc_pred.F90).

## Blacklisting

### Preparation for radiance monitoring
 Radiances sensed by polar orbiting satellites like NOAA and Meteop series are accessible differently at different assimilation time for different LAM model. This means that we use these data differently in different Harmonie LAM models. To make the assimilation optimal for our domain, we need to monitor the accessibility of data from different instruments inside our model domain. There are two ways of monitoring the radiance data assimilation: - 1) we do passive assimilation of the radiances using the assimilation and forecast systems; - 2) when having forecasts with the system, which we would like to use when assimilating the radiance data, then we can do independent assimilations of radiances with the first guess from the existing mentioned results.
### = Monitoring with passive data assimilation=

 There two ways of monitoring the availability and assimilation of polar orbiting-based radiances. In any case we assimilate the radiances in passive way by changing some settings in the [srs/blacklist/mf_blacklist.b](https://hirlam.org/trac/browser/Harmonie/srs/blacklist/mf_blacklist.b) as follows at the end of blacklisting procedure for each instrument. Please read carefully this paragraph until the end before starting your passive experiment. Below is the example for AMSU-A radiances:
```bash

 ...
! begin passive
        fail(EXPERIMENTAL);
! end passive

    endif;   ! SENSOR = AMSUA
```

This way we guarantee that the blacklisting rules for active radiances are applied, which is very important when we change to active assimilation.

### = Monitoring using the Obsmon tool=

To have the all statistics we need when using the **Obsmon** tool, in [ecf/config_exp.h](https://hirlam.org/trac/browser/Harmonie/ecf/config_exp.h) set the following:
```bash
# *** Observation monitoring ***
OBSMONITOR=obstat               # Create Observation statistics plots
```

Note that running the Harmonie system with this option may slow down you monitoring process. Instead, you can run the Obmon separately. More about the Obsmon monitoring tool can be found [here].[[BR]](./PostPP/Obsmon.md)

### = Cold start=
 This way of monitoring is defined the following way in Harmonie through the [scr/include.ass](https://hirlam.org/trac/browser/Harmonie/scr/include.ass):
```bash
# Start with empty VARBC coefficients
export VARBC_COLD_START=yes # yes|no
```

In this way **the estimation starts with zero coefficients and we need minimum 20 days** to have the bias for different channels well converging to their nominal values. This is the common practice in Hirlam community, but some studies in LACE showed that warmstart can be advantageous.
### = Warm start=
 This way we start with precomputed varBC coefficients from other LAM or from a global model. See the section on "**activating existing varBC coefficients**" below. We set our choice in [scr/include.ass](https://hirlam.org/trac/browser/Harmonie/scr/include.ass) the following way:{{{
# Start with empty VARBC coefficients
export VARBC_COLD_START=no # yes|no
```

### = Monitoring with independent analyses and without Obsmon=
 This solution needs additional playfile, which is not yet implemented in the Harmonie system. The playfile avoid the extraction of the LBCs, execution of the forecast and the post-processing parts of the Harmonie system. On top of the screening and minimization, it takes into account of the archiving part of the odb data.

Once you have the ODB database after a month of experiment with analyses only, you can extract the the first-gess departures (fg_depar) and the analysis increments (an_depar) using the scripts in [this tarbal](https://hirlam.org/trac/attachment/wiki/HarmonieSystemDocumentation/ObservationHowto/Atovs/For_WW.tar). When the extraction is finished, you can compute the statistics using the [this tool](https://hirlam.org/trac/attachment/wiki/HarmonieSystemDocumentation/ObservationHowto/Atovs/For_WW2.tar). Use the script called "ExtractOdb_??" to extract the departure information. To compute the statistics, use the script called "checkbias_??". To plot the final results you can use the R-based scripts in [this tartbal](https://hirlam.org/trac/attachment/wiki/HarmonieSystemDocumentation/ObservationHowto/Atovs/R_Plots.tar) file.

### = Analysing the results=

  * **Using obsmon **
To check the efficiency of the assimilation of each channel extracted by Bator use the obcmon abd make your choice similar to the example below. Make sure that you have chosen your experiment and set up the period for the whole period of your monitoring.

Then plotting the results, you should have something similar to the example below:

Take note about the channels that behave badly (having large bias an_depar over Land or Sea) at different assimilation time. Note that for AMSU-B and MHS, the observation error is relatively larger than that of the AMSU-A. So, you can allow larger bias than for AMSU-A. See the examples bellow.

  * **Not using obsmon **

The good point of choosing this tool is that the results are more compacted in only few eps-formatted files, which makes the analysis easier than with Obsmon. The analysis procedure is the same.

When the assimilation of the ATOVS radiances at all assimilation times was checked, then use the blacklisting rules described below to make your final choice for your LAM model with ATOVS.

### Blacklisting rules

  Once we have the list of the bad channels for each of the assimilation time you'd like to apply your ATOVS assimilation, the follow the rules described below. Let take the following decision for example. We need to blacklist the channels 5,6,7, 8 from NOAA-18 AMSU-A 12 UTC. How to register the bad channels in the file called LISTE_LOC_${HH} is described in [this presentation](https://hirlam.org/trac/attachment/wiki/HarmonieSystemDocumentation/ObservationHowto/Atovs/28_Bp_workshop1n_n_RogerR.ppt).
According to our example, we create the file called **LISTE_LOC_12** with the following content:{{{
N  7 210      209       3 TOVS4       5       6       7       8
N  7 210      209       3 TOVS5      11      12      13      14      15
```

The first line means: N      - blacklist 7      - satem observation 210    - level 1c 209    - NOAA-18 3      - AMSU-A TOVS4  - blacklist 4 channels, which are 5, 6,7 and 8
Put the LISTE_LOC_$HH files under the "nam" directory.

### Set up the VarBC coefficients for your experiment or operational data assimilation

### = For experiments=

Here we have already the VarBC coefficients, so **we do warm start** (see setup above). her is the procedure:
 - Fetch the VARBC.cycle files from the latest odb_stuff.tar for each assimilation time. In case of 3h cycling, we fetch the VARBC.cycle from the latest 8 cycles. Rename them the following way: VARBC.cycle.$DOMAIN.$EMONTH.$HH, where EMONTH can be SUMMER or WINTER. Like for example: VARBC.cycle.AROME_Arctic.SUMMER.12.
 - Put these files under "const/bias_corr/"

These files are arranged this Fetch_assim_data the following way:
For all Hamonie cycles up to 40:
```bash
     # Fetch data
       if [ ! -s ${DLOCVARBC}/VARBC.cycle] ; then

         echo "Fetch the data from $HM_LIB/const/bias_corr"
         # Set the proper VARBC period for coefficients
         case $MM in
           10|11|12|01|02|03)
             EMONTH=WINTER
           ;;
           04|05|06|07|08|09)
             EMONTH=SUMMER
           ;;
           *)
             echo "This should never happen. MM is $MM"
             exit 1
         esac

         cp $HM_LIB/const/bias_corr/VARBC.cycle.$DOMAIN.$EMONTH.$HH ${DLOCVARBC}/VARBC.cycle || \
         { echo "Could not find cold start VARBC data VARBC.cycle.$EMONTH.$HH" ; exit 1 ; }
              ls -lrt ${DLOCVARBC}
       fi
```

From cycle 43:
```bash
     # Fetch data
       if [ ! -s ${DLOCVARBC}/VARBC.cycle] ; then

         echo "Fetch the data from $HM_LIB/const/bias_corr"
         # Set the proper VARBC period for coefficients
         case $MM in
           10|11|12|01|02|03)
             EMONTH=WINTER
           ;;
           04|05|06|07|08|09)
             EMONTH=SUMMER
           ;;
           *)
             echo "This should never happen. MM is $MM"
             exit 1
         esac

         cp $HM_LIB/const/bias_corr/${DOMAIN}/VARBC.cycle.$HH ${DLOCVARBC}/VARBC.cycle || \
         { echo "Could not find cold start VARBC data VARBC.cycle.$EMONTH.$HH" ; exit 1 ; }
              ls -lrt ${DLOCVARBC}
       fi
```

With a tiny difference that all the VarBC files are now stored under a ${DOMAIN} directory. This allows our system to be up-to-date and ready for all known model domains. Please send your VarBC files to the system administrators.

### = For operational implementation=

The setup is much easier. Name the VARBC.cycle files the following way "VARBC.cycle.${HH} and put them in "$ARCHIVE_ROOT/VARBC_latest", which you need to create.

To check that you have done things right: * Doing experiment: Check that you have all LISTE_LOC_$HH files under the "nam" directory, and the VARBC.cycle.$DOMAIN.$EMONTH.$HH files under "const/bias_corr" directory.
 * Operational implementation: Check that you have all LISTE_LOC_$HH files under the "nam" directory, and the VARBC.cycle.$HH under the $ARCHIVE_ROOT/VARBC_latest directory.
If you passed the test, then **you are ready** with ATOVS implementation. Congratulation!


text:
# Jetson Virtual Touchpanel Tool

This tool enables Jetson UI screen to be controlled by hand gesture using an inexpensive RGB camera and AI handpose recognition.

It is primarily desigend for interactive signage systems.

By utilizing a camera and GPU-accelerated handpose recognition to understand the users hands in real-time, this tool enables users to interact with the UI screen without physically touching the touchpanel or ohter input devices like a mouse.

This tool is based on the following software.
- [`trt_pose`](https://github.com/NVIDIA-AI-IOT/trt_pose) : Underlying work that enables real-time pose estimation on NVIDIA Jetson
- [`trt_pose_hand`](https://github.com/NVIDIA-AI-IOT/trt_pose_hand) : Handpose detection model, gesture classification training and inference logics are derived from this repo.

## Hardware requirement

- Jetson NX Xavier
- USB webcam

## Software setup

### jetson_virtual_touchpanel

If not, clone this repo.

Make sure it's placed in the $HOME directory.

We need following software on Jetson (docker host) to run this tool.

```
sudo apt-get update
sudo apt-get install -y python3-pip
pip3 install pyzmq pynput
```

### Download models

Currently, this tool needs two different models;

- trt_pose model : For handpose detection. Below you can download the TRT optimized model for Jetson Xavier NX.
- SVM model : For understanding the user's gesture

Download the following two files and put them both under `~/jetson_virtual_touchpanel/pub/model`.

| Model | Class | Trained with | Optimized for | Download | original |
|-------|-------|--------------|---------------|----------|----------|
| trt_pose model | `hand` | 2600 images | Jetson Xavier NX |  [handpose_resnet18_att_224x224_nvhand-2k6_trt.pth](https://drive.google.com/file/d/1ALFjVq8gfE0tcvtHuMpu0Qsi_oSRfkWw/view?usp=sharing) | hand_pose_resnet18_baseline_att_224x224_A|

| Model | Class | Trained with | Download |
|--------|-----------------|----------------|--------|
| SVM model | `no-hand`, `pan`, `point`, `click`, `(other)` | 200 images | [svmmodel_5class.sav](https://drive.google.com/file/d/1AO-wU5ftYy6SEhoJurCMX5NKDW-0HF2Z/view?usp=sharing) |

> For training your own SVM model for custome gesture classification, check out the [gesture_data_collection_pose.ipynb](https://github.com/NVIDIA-AI-IOT/trt_pose_hand/blob/main/gesture_data_collection_pose.ipynb) and [gesture_data_collection_pose.ipynb](https://github.com/NVIDIA-AI-IOT/trt_pose_hand/blob/main/gesture_training/train_gesture_classification.ipynb) Jupyter notebooks in [`trt_pose_hand`](https://github.com/NVIDIA-AI-IOT/trt_pose_hand) repo.

### Set up jetson-pose-container

```
cd
git clone https://github.com/tokk-nv/jetson-pose-container
cd jetson-pose-container
./scripts/set_nvidia_runtime.sh
```

Also, make `docker` command available without using `sudo`.

```
sudo groupadd docker
sudo usermod -aG docker $USER
```

Reboot, and make sure you can just start the jeston-pose container without using `sudo`.

```
cd
cd jetson-pose-container
./run.sh
```

It should pull the container image from Docker Hub and once that is done it should launch into the terminal within the container.

You can type `exit` to come out.

## How to use

### Physical setup

- Plug a USB webcam to Jetson NX.

> Make sure a device (like `/dev/video0`) is seen on your system. Depending on the device name (number), you need to edit the script (`pub/trtpose_handpose/pub_hand_msg_thread.py:L126`).

- HDMI display

> Connect an HDMI display and make sure the resolution is set to `1920x1080`.

### How to start

On the GUI desktop, open a terminal (`Ctrl` + `Alt` + `t`), then issue the following commands to invoke the indicator script.

```
cd virtual_touchpanel
python3 vtouch_indicator.py
```

You will see a gray-out indicator icon in the desktop top panel bar.

Click on the icon, then select "Start camera-pose service".

![](/docs/images/vtouch_menu_start.png)

This will launch a service (Docker container) that opens the camera and run the trt_pose model to send the recognized handpose data to this tool via ZMQ.

The tool interprets the data and use `pynput` to contol the UI screen simulating mouse input.

> You can still use system's native keyboard and mouse to control the system.

### How to use

- Mouse movement: Hover your hand infront of camera, the tip of your index finger determines the mouse cursor
- Mouse click: From the state where only your index finger is extended, do the "pinching" motion with your thumb

### How to end

To stop the service, from the Virtual Touchpanel UI menu, select "Stop camera-pose service".

It will take some time (~10sec) to stop the docker container.

To shutdown the tool completely, select "Quit" from the Virtual Touchpanel UI menu.

## Usage scene

- Interactive signage
  - Promotion that lets users to input their info for getting coupons
  - Directory/wayfinding (mall, airport, library, etc.)
- Check-in system for pick-up (user input receipt number)
- Check-in system for health screening

## TODO

- [ ] Support CSI camera (with exposure time control)
- [ ] Optimize ZMQ message handling
- [ ] Support various monitor resolution and

branch_name: refs/heads/main

extension: md

license_type: permissive


text:
TOC -->

- [Overview](#overview)
- [Installation and usage](#installation-and-usage)
- [Helpers for developers](#helpers-for-developers)
- [Production](#production)
- [Something is missing ?](#something-is-missing-)
- [Changelog](#changelog)
- [:warning: Backward incompatible changes](#warning-backward-incompatible-changes)
- [Contribution](#contribution)

## Overview

You just want to try Ghost without messing up your computer? (and that's why you already have docker installed)

> simply run `make` and head to <http://localhost:3001>

You want to play a bit more, and you would like to have multiple Ghosts on your domain / server?

* Either use *make* again and again with different variables, to get your blogs on a **per-port basis**
    > e.g.: `NAME=another PORT=3002 make` for a second blog on <http://localhost:3002>
* or leverage the power of [traefik](https://traefik.io) and have multiple ghosts on a **per-path basis** (see section below)
    > e.g.: `NAME=yet-another make qa`. Head to <http://localhost/yet-another>

By the way, you would like to run an old version of Ghost ? `GHOST_VERSION=x.x.x make qa` will do this for you. You can use whatever version is available on [docker hub](https://hub.docker.com/_/ghost)

If you are worried with your data, be at rest: a local folder is created within path _./instances_, for every blog you create, named from $NAME variable. Stopping and restarting a blog with the same name will keep using the local data.

## Installation and usage

Command | Description | Remarks
---------|----------|---------
 `make` | straightforward (local) installation if you simply wish to bridge a container port on your host (3001 by default) | also known as `make dev`
 `make qa` | The former being not really convenient if you wish to serve on standard ports (80 or 443), and if you want anyone to access your blog easily, this command sets up a traefik router | recommended usage of [prod-stack](https://github.com/ebreton/prod-stack)
 make prod | Same as above, using a MariaDB instead of SQLite and an email provider (Mailgun) | requires a (free) account at Mailgun

You will find details and a step-by-step guide for both scenario in [INSTALL.md](./docs/INSTALL.md)

If you'd rather have a **Tutorial** than a raw INSTALL.md file, feel free to check my "_Ghost in A shell_" series:
1. [Part I : localhost](https://dev.to/ebreton/ghost-in-a-shell---part-i--localhost-5he9)
1. [Part II : HTTPs is the norm](https://dev.to/ebreton/ghost-in-a-shell---part-ii---https-is-the-norm-1jj4)
1. [Part III - To Production, with performance](https://dev.to/ebreton/ghost-in-a-shell---part-iii--to-production-with-performance-10g5)
2. [Part IV - Maintenance](https://dev.to/ebreton/ghost-in-a-shell---part-iv-and-final-maintenance-2a5p)

## Helpers for developers

Now that you have one (or more) blogs running, you might want to check their status, or access the containers...

A few helpers are provided within the Makefile:

Command | Description | Variables
---------|----------|---------
 `make vars` | Display the values of all env vars | All
 `make ps` | Display the running containers | None
 `make cli-version` | Display Ghost & ghost-cli version, + latest version available on docker hub | NAME
 `make shell` | Connect to given Ghost container | NAME
 `make logs` | Tail and follow the logs of given Ghost container | NAME
 `make stop` | Stop given Ghost container | NAME
 `make pull` | Update docker image from dockerhub | None
 `make restart` | Calls `make stop qa logs` | NAME (and from `make qa`: PROTOCOL, DOMAIN, URI)
 `make upgrade` | Calls `make pull restart` | same as above
 make gatling     | Execute load tests | GATLING_BASE_URL, GATLING_USERS, GATLING_RAMP

More detailed can be found in [HELPERS.md](./docs/HELPERS.md)

## Production

Environment variables are defined in ./etc/prod.env, e.g:
- MYSQL_ROOT_PASSWORD
- MAILGUN_LOGIN
- MAILGUN_PASSWORD

Command | Description
---------|----------
 make prod          | Runs Ghost behind a proxy (Nginx+Traefik), on HTTPs, with a (Maria)DB and Mailgun email provider
 `make restart-prod` | Calls `make stop prod logs`
 `make upgrade-prod` | Calls `make pull restart-prod`

## Something is missing ?

Head to [github issues](https://github.com/ebreton/ghost-in-a-shell/issues) and submit one! Be sure to have a look at the [CONTRIBUTING.md](./docs/CONTRIBUTING.md) guide before

## Changelog

All notable changes to this project are documented in [CHANGELOG.md](./CHANGELOG.md).

## :warning: Backward incompatible changes

- :boom: v0.2.0 : data volumes are now created within subfolder ./instances. You will need to move your data from the root folder into this new place
- :alarm_clock: v0.4.0: `make traefik` replaced with `make qa` instead

## Contribution

Check out [CONTRIBUTING.md](./docs/CONTRIBUTING.md) for more details

As well as our [CODE_OF_CONDUCT.md](./docs/CODE_OF_CONDUCT.md), where we pledge to making participation in our project and our community a harassment-free experience for everyone

license: MIT

repository: ebreton/ghost-in-a-shell

branch_name: refs/heads/master

gha_language: Python

gha_license_id: MIT

repo_name: ebreton/ghost-in-a-shell


text:
# Changelog
All notable changes to this project (fork) will be documented in this file.

The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
and this project (fork) adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html)
since version 4.1.0.

## [Unreleased]

## [4.1.0] - 2018-08-30
### Fixed
- broken reassembly of fragmented packets [Joerg Boehnel]
- build errors on macOS+clang

repository: alexandrepgfreitas/RakNet

gha_language: HTML

gha_license_id: NOASSERTION

repo_name: alexandrepgfreitas/RakNet


text:
uemacs
======

MicroEMACS, a.k.a.uemacs, ported from FreeBSD ports collection, [(http://debian.physik.uni-essen.de/misc/memacs/disk2/ue400dev.zip)]

uemacs is intended to be a small, fast, and portable editor for people who
can't (or don't want to) run emacs for one reason or another, or are not
familiar with the vi editor. It is compatible with emacs because there
shouldn't be any reason to learn more editor types than emacs or vi.

This repository aggressively tracks upstream.

Compiling
---------
`uemacs` use directly a hand-written `POSIX` `Makefile`.
```
$ make -j8
$ make install
```

To uninstall `uemacs`, execute:

```
$ make uninstall
```
Or:

```
$ make deinstall
```

Dependencies
------------
By default, you need the ncurses library.

NetBSD users will use the in-base NetBSD curses library.

If you do not have the ncurses library, you must install it first.
There are no extra dependencies other than the system's libc and ncurses.

Testing
-------
Tested on recent versions of Arch, Alpine, Cygwin, Debian, DragonFly BSD,
FreeBSD, Mac OS X (10.4 or later), NetBSD, Slackware, and Ubuntu.

repository: HannaCun/uemacs

repo_name: HannaCun/uemacs


text:
Linux / Unix Desktop Fun: Text Mode ASCII-art Box and Comment Drawing
================================================================================
Boxes command is a text filter and a little known tool that can draw any kind of ASCII art box around its input text or code for fun and profit. You can quickly create email signatures, or create regional comments in any programming language. This command was intended to be used with the vim text editor, but can be tied to any text editor which supports filters, as well as from the command line as a standalone tool.

### Task: Install boxes ###

Use the [apt-get command][1] to install boxes under Debian / Ubuntu Linux:

    $ sudo apt-get install boxes

Sample outputs:

    Reading package lists... Done
    Building dependency tree
    Reading state information... Done
    The following NEW packages will be installed:
      boxes
    0 upgraded, 1 newly installed, 0 to remove and 6 not upgraded.
    Need to get 0 B/59.8 kB of archives.
    After this operation, 205 kB of additional disk space will be used.
    Selecting previously deselected package boxes.
    (Reading database ... 224284 files and directories currently installed.)
    Unpacking boxes (from .../boxes_1.0.1a-2.3_amd64.deb) ...
    Processing triggers for man-db ...
    Setting up boxes (1.0.1a-2.3) ...

RHEL / CentOS / Fedora Linux users, use the [yum command to install boxes][2] (first [enable EPEL repo as described here][3]):

    # yum install boxes

Sample outputs:

    Loaded plugins: rhnplugin
    Setting up Install Process
    Resolving Dependencies
    There are unfinished transactions remaining. You might consider running yum-complete-transaction first to finish them.
    --> Running transaction check
    ---> Package boxes.x86_64 0:1.1-8.el6 will be installed
    --> Finished Dependency Resolution
    Dependencies Resolved
    ==========================================================================
     Package        Arch            Version               Repository     Size
    ==========================================================================
    Installing:
     boxes          x86_64          1.1-8.el6             epel           64 k
    Transaction Summary
    ==========================================================================
    Install       1 Package(s)
    Total download size: 64 k
    Installed size: 151 k
    Is this ok [y/N]: y
    Downloading Packages:
    boxes-1.1-8.el6.x86_64.rpm                         |  64 kB     00:00
    Running rpm_check_debug
    Running Transaction Test
    Transaction Test Succeeded
    Running Transaction
      Installing : boxes-1.1-8.el6.x86_64                                 1/1
    Installed:
      boxes.x86_64 0:1.1-8.el6
    Complete!

FreeBSD user can use the port as follows:

    cd /usr/ports/misc/boxes/ && make install clean

Or, add the package using the pkg_add command:

    # pkg_add -r boxes

### Draw any kind of box around some given text ###

Type the following command:

    echo "This is a test" | boxes

Or specify the name of the design to use:

    echo -e "\n\tVivek<EMAIL_ADDRESS>| boxes -d dog

Sample outputs:

![Unix / Linux: Boxes Command To Draw Various Designs](http://s0.cyberciti.org/uploads/l/tips/2012/06/unix-linux-boxes-draw-dog-design.png)

Fig.01: Unix / Linux: Boxes Command To Draw Various Designs

#### How do I list all designs? ####

The syntax is:

    boxes option
    pipe | boxes options
    echo "text" | boxes -d foo
    boxes -l

The -d design option sets the name of the design to use. The syntax is:

    echo "Text" | boxes -d design
    pipe | boxes -d desig

The -l option list designs. It produces a listing of all available box designs in the config file, along with a sample box and information about it's creator:

    boxes -l
    boxes -l | more
    boxes -l | less

Sample outputs:

    43 Available Styles in "/etc/boxes/boxes-config":
    -------------------------------------------------
    ada-box (Neil Bird ):
        ---------------
        --           --
        --           --
        ---------------
    ada-cmt (Neil Bird ):
        --
        -- regular Ada
        -- comments
        --
    boy (Joan G. Stark ):
                        .-"""-.
                       / .===. \
                       \/ 6 6 \/
                       ( \___/ )
          _________ooo__\_____/______________
         /                                   \
        |   joan stark<EMAIL_ADDRESS> |
        |     VISIT MY ASCII ART GALLERY:     |
        | http://www.geocities.com/SoHo/7373/ |
         \_______________________ooo_________/  jgs
                        |  |  |
                        |_ | _|
                        |  |  |
                        |__|__|
                        /-'Y'-\
                       (__/ \__)
    ....
    ...
    output truncated
    ..

### How do I filter text via boxes while using vi/vim text editor? ###

You can use any external command with vi or vim. In this example, [insert current date and time][4], enter:

    !!date

OR

    :r !date

You need to type above command in Vim to read the output from the date command. This will insert the date and time after the current line:

    Tue Jun 12 00:05:38 IST 2012

You can do the same with boxes command. Create a sample shell script or a c program as follows:

    #!/bin/bash
    Purpose: Backup mysql database to remote server.
    Author: Vivek Gite
    Last updated on: Tue Jun, 12 2012

Now type the following (move cursor to the second line i.e. line which starts with "Purpose: ...")

    3!!boxes

And voila you will get the output as follows:

    #!/bin/bash
    /****************************************************/
    /* Purpose: Backup mysql database to remote server. */
    /* Author: Vivek Gite           */
    /* Last updated on: Tue Jun, 12 2012                */
    /****************************************************/

This video will give you an introduction to boxes command:

注：youtube 视频
<iframe width="595" height="446" frameborder="0" src="http://www.youtube.com/embed/glzXjNvrYOc?rel=0"></iframe>

(Video:01: boxes command in action. BTW, this is my first video so go easy on me and let me know what you think.)

See also

- boxes man page

--------------------------------------------------------------------------------

via: http://www.cyberciti.biz/tips/unix-linux-draw-any-kind-of-boxes-around-text-editor.html

作者：Vivek Gite
译者：[译者ID](https://github.com/译者ID)
校对：[校对者ID](https://github.com/校对者ID)

本文由 [LCTT](https://github.com/LCTT/TranslateProject) 原创编译，[Linux中国](https://linux.cn/) 荣誉推出

[1]:http://www.cyberciti.biz/tips/linux-debian-package-management-cheat-sheet.html
[2]:http://www.cyberciti.biz/faq/rhel-centos-fedora-linux-yum-command-howto/
[3]:http://www.cyberciti.biz/faq/fedora-sl-centos-redhat6-enable-epel-repo/
[4]:http://www.cyberciti.biz/faq/vim-inserting-current-date-time-under-linux-unix-osx/

url: https://raw.githubusercontent.com/TimLang/TranslateProject/5d936a2ac8298afcb0e0a2bfbe2348554b85fb59/sources/tech/20151215 Linux or Unix Desktop Fun--Text Mode ASCII-art Box and Comment Drawing.md

repository: TimLang/TranslateProject

repo_name: TimLang/TranslateProject


text:
# docker-nexus

A Docker image for OpenLDAP.

## Running

In development and test environments, it is often sufficient to run:

        docker run -p 8389:8389 decipher/openldap:<tag>

If you wish to perist directory data across restarts you will need to mount a volume at `/var/lib/openldap`.

        docker run -p 8389:8389 -v ${PWD}/openldap:/var/lib/openldap decipher/openldap:<tag>

Additionally, this image supports configuration via a number of environment variables.

| Variable               | Default                   | Description                               |
|------------------------|---------------------------|-------------------------------------------|
| ROOT_DN                | cn=root,dc=example,dc=com | The distinguished name of the root entry. |
| ROOT_PW                | password                  | The password for the root entry.          |
| ROOT_SUFFIX            | dc=example,dc=com         | The root suffix for the directory.        |
| TLS_CA_CERTIFICATE     | *Base64 TLS Certificate*  | The base64 encoded CA certificate.        |
| TLS_SERVER_CERTIFICATE | *Base64 TLS Certificate*  | The base64 encoded server certificate.    |
| TLS_SERVER_KEY         | *Base64 TLS Key*          | The base64 encoded server key.            |

Lastly, the TLS certificates and keys may be mounted directly and this will override the environment variables above.

| Mount                        | Description             |
|------------------------------|-------------------------|
| /etc/openldap/tls/ca.crt     | The CA certificate.     |
| /etc/openldap/tls/server.crt | The server certificate. |
| /etc/openldap/tls/server.key | The server key.         |

## Using

Once running the LDAP server can be reached at ldap://localhost:8389/:

        ldapwhoami -D cn=root,dc=example,dc=com -w password -H ldap://localhost:8389/ -ZZ

## Building

To build the image run:

        ./build.sh

## Publishing

To build and publish the image run:

        ./publish.sh

## Contributing

1. Fork it
1. Create your feature branch (`git checkout -b my-new-feature`)
1. Commit your changes (`git commit -am 'Add some feature'`)
1. Push to the branch (`git push origin my-new-feature`)
1. Create new Pull Request

repository: DecipherNow/docker-openldap

gha_language: Dockerfile

repo_name: DecipherNow/docker-openldap


text:
# Mutable Variables

The mutable storage class specifier in C++ (or use of mutable keyword in C++)
auto, register, static and extern are the storage class specifiers in C. typedef is also considered as a storage class specifier in C. C++ also supports all these storage class specifiers. In addition to this C++, adds one important storage class specifier whose name is mutable.

GeeksForGeeks.org

-----
## Sample1.cpp
Wrong Code:
```C++
    const Sample sample(10,10);
    cout<<"X:\t"<<sample.x<<endl;
    sample.x += 10;
    cout<<"X:\t"<<sample.x<<endl;
```

repository: nimaiji/sample-cpp

repo_name: nimaiji/sample-cpp


text:
# Archery
Point-and-click archery game played in a web browser.

![game screenshot](https://github.com/michaelhtleung/Archery/blob/master/img/aiming-cropped.png)

## Try It Out!
[https://michaelhtleung.github.io/Archery/](https://michaelhtleung.github.io/Archery/)

## Controls
- move your cursor to aim the bow and left-click to place the bow
- move your cursor to aim the arrow and control its speed and left-click to fire the arrow
- left-click to retrieve your arrow and repeat the above two-steps to continue playing

## Features
- [x] projectile motion
- [x] sprite and tile-graphics for bow, arrow, crosshair, board, background, and grass
- [x] arrow-target and arrow-ground collisions
- [x] vertically moving board
- [x] mouse control scheme
- [x] pivoting the bow based on the location of the crosshair
- [x] rotating the arrow based on its velocity in flight
- [x] having the arrow get stuck in the target at whatever orientation it was in prior to hitting the target
- [x] random grass generation

repository: michaelhtleung/Archery

repo_name: michaelhtleung/Archery


text:
# Tailwind Elements

### Collection of free, popular components like modal, dropdown, carousel, popover, cards, charts and many more.

---
[![Tailwind Elements](https://tailwind-elements.com/img/tailwind-elements.jpg)](https://tailwind-elements.com/)

Tailwind Elements **does not change or add any CSS** to the already one from TailwindCSS.

You can **copy our components directly** into your Tailwind design and **they will work straight away**.

In some dynamic components (like dropdowns or modals) we add Font Awesome icons and custom JavaScript. However, they do not require any additional installation, all the necessary code is always included in the example and copied to any Tailwind project - it will work.

---

## Quick Start tutorial

[![Quick Start tutorial](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/video.jpg)](https://www.youtube.com/watch?v=RAhugF8NOBs)

![Carousel](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/carousel.gif)
![enter image description here](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/1.jpg)
![Buttons](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/buttons.gif)

![Alerts](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/2.jpg)
![Chart](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/chart.gif)
![Alerts](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/3.jpg)
![Datepicker](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/datepicker.gif)
![Chart Linear](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/4.jpg)
![Loaders](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/loaders.gif)
![Badges](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/5.jpg)
![Dropdown](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/dropdown.gif)
![Progress](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/6.jpg)

![enter image description here](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/7.jpg)

![enter image description here](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/9.jpg)

![enter image description here](https://mdbootstrap.com/img/Marketing/campaigns/tailwind/8.jpg)


text:
# API

## Technologies

This is the API for Catchup, an application written IvyHacks 2020.
The server is written using Node.js, Express, and TypeScript.

## Development

Start the development server:

```sh
npm run dev
```

Compile the server for production:

```sh
npm run build
```

repository: CatchupApp/api

repo_name: CatchupApp/api


text:
Prerequisite:

sudo apt-get install terminator
or
sudo yum install terminator

termssh is a script to create and maintain gnome terminator layouts for ssh access either via:

 -g    | Auto groups servers per apptype conventions,

 -fs   | Full screen options,

 -w 8  | window per tab definition of 2 4 or 8 windows per tab

 -n "my layout" | this will set the layout name to a familiar name of your choice for future connections

 -vp 122 | This is for vpn users and this is what you define as your vpn port

 -v hostname | this is the vpn hostname used to connect through

 -s "gateway-(lon|gla)[01-02] myql[01-03] apache01"    | in speech marks space seperated list

 -f filename  |  to connect to servers in a filename, can contain wild card naming like above

 -l {env} {apptypes} {service_type}   | to TEST autodiscovery of servers and show what servers are being generated

 -c to reconnect to existing layout | existing layouts listed and you can numerically choose which layout

## Testing termssh

To understand the power of grouping -g simply place entire code in DEBUG mode, at the top of termssh script find DEBUG which is set to 0 change this to 1.
Save script then on command line type in:

## termssh.bc
Copy this file to /etc/bash_completion.d/termssh, the next shell session to your host will now process auto completion on termssh, this returns valid switches and
allows you to connect to existing saved layouts, type in termssh press tab and a list of options are shown. Type in termssh conn press tab then tab again and it will list all saved profiles.
You can start typing in some and pressing tab for it to complete the connection for you

## Normal pattern match using -s to define hosts - must be wrapped - Auto Discovers

# termssh -r -w 8 -g -n "agm1" -x 2 -s "gw-(lon|gla)[01-02] mql[01-03] apache01"

This will open 8 window terminator session with apaches in group
The layout name will be called agm1 for future connections
The naming convention matches the scripts defined naming convention i.e. gw mql apa which then the -g grouping kicks
in and groups servers per app type
It will connect twice per server -x 2
Finally pattern match servers called gw-lon-01 gw-gla-01 gw-lon-02 gw-gla-02 mql01 mql02 mql03 and finally apache01
and then check if their available if so 2 terminator connections per host will be launched with 8 windows per tab

In this instance my server names matched that naming convention which then got processed by group function below it.

Whilst DEBUG=1 at top of termssh

# termssh -r -w 4 -x 2 -g -s "apa[01-02]"

This will launch -x 2 i.e. connections to apa01 and apa02 twice for each host.
The grouping works out you have two connections to the host so assigns group-1 to apa01 apa02 first time around
and group apache-2 to apa01 and apa02 for 2nd set of connections.

This means you can now type in for example tail -f /var/log/messages on one of the apaches which sends it to one set of the servers
and then restart a service by typing it to 2nd instance of apa01 which gets sent to apa02 as part of group-2

hope it makes sense.

Enable debug mode at top of the script and try out:

# termssh -r -n "apa-gw-mql" -w 8 -x 2 -fs -g -s "apa[01-04] mql[01-02] gw[01-02]" space seperated list

then type in a command into any of the apache-1 sessions.

This will -r remove layout -w 8 try for 8 windows  and because -x = 2 this means 4 servers twice which equals the 8 windows defined full screen and will autogroup (-g)

 apache01 connection 1 will be part of apache-1 group

 apache01 connection 2 will be part of apache-2 group|

 apache02 connection 1 will be part of apache-1 group

 apache02 connection 2 will be part of apache-2 group

layout name for future connection:  apa-gw-mql

## -s Example with extra verbosity:

 # termssh.sh -n "bad" -r  -s "local(h|i)os[s-t] local(h|i)os[s-t]"

 [[mylayer]]

user you have issued -r : Layout bad has now been removed !!

Will recreate bad

___ Blanked out tmp file /tmp/terminator-hosts-1000.collect.tmp

___ localhoss

___ localhost

___ localioss

___ localiost

___ localhoss

___ localhost

___ localioss

___ localiost

Total servers 2 | Tabs required 1 | LAYOUT= bad ./termssh1.sh -c to reconnect

##  File method - pattern matches

# termssh -r -w 8 -n "my mail servers" -f ./mailservers.txt

-f option to call the file and create layouts layout names will be the filenames so ensure you use different file names each time a new group is created.

-w 8 is windows and you can define 2 4 or 8 servers per tab

-r is to remove existing layout, required if you wish to refresh a layout in cases where new servers have been added to either text file or as part of network with auto discover. if -r is not given and layout already exists - the layout will be loaded instead of discovery or reading file

This will read each value in the filename and create a layout called mailservers which contains each server - 8 windows per tab
to reconnect in the future either run termssh -c or rerun above which locates existing layouts and auto connects|

layout name for future connection:  my mail servers

# termssh -r -w 8 -x 2  -fs  -f ./webservers.txt

-fs full screen mode - if fullscreen option at top is set to 0 then use this to make it full screen use -r in conjunction for existing layouts

-x 2 Amount of times to reconnect per host this also auto groups each server per run so two apache servers  with -x 2 = 4 servers group apache-1 for instance 1 of each server and group-2 for instance 2 of each server

This will read each value in the webservers.txt file  and create a layout called webservers, it will then run through -x value and connect that many times to each host
Servers can be a combination of specific names or pattern match :
localhost

localhost

loca(l|h)[h-s]ost

## VPN Connections / SSH REVERSE TUNNEL Connections

This allows you to define a vpn host and port - the problem may come into effect for pattern match
since if current connection requires a vpn to connect the script using nc will not be able to catch port 22
thus pattern match will fail

 termssh.sh -n "vpncon" -r -vp 222 -v windows_host -s "local(h|i)os[s-t] local(h|i)os[s-t]"

The above would probably fail - check_method at the top of script can be changed to ping so long as it can resolve short names locally
I would suggest for vpn to either use -f and have all servers listed in a text file or do something like:

# termssh.sh -n "vpncon" -r -vp 222 -v windows_host -s "server1 server2 server3 server4"
or

# termssh.sh -n "vpncon" -r -vp 222 -v windows_host -s "server[1-4]"

So long as the pattern match matches exact server convention start/end. This would result in the expanded list matching initial input above it

This way it will do ssh -tt -p $VPN_PORT $VPN_SERVER -c "ssh $current_server" for each server in the list

 querymethod is automatically disabled for vpn connections which in short disable server validation

## SSH Reverse tunnel connections:

remot_server issue:
# ssh -R1999:localhost:22 vahid@my_local_host

To connect through my reverse tunnel same as vpn:

where -n is layout name

 -v is vpn host (included my ldap username)

 -vp is vpn port

 -s is server input within speech marks

#termssh -r -n "test2" -v "remote_username@localhost" -vp 1999 -s "apache01 apache02"

or

#termssh -r -n "test2" -v "remote_username@localhost" -vp 1999 -s "apache[01-10]"

Which will connect from apache01 to apache10 servers, the remote_username@localhost can seem confusing but you would define the username used on remote network that you are reversing from
the initial

## Help
# termssh -h

options:

-r  | --removelayout                            |  remove layout and refresh it

-fs | --fullscreen                              |  start session in full screen mode, Override FULL_SCREEN_MODE=0

-g | --group                            |  groups server as per naming set_apptype, Override AUTO_GROUPING_ENABLED=0

-w  | --windows  [2/4/8 ]                       | -w followed by 2 or 4 or 8 windows per tab

-x  | --times  [1-10 ]                          | -x followed by 1 to any number above - reconnect value per server

-n  | --layoutname  "something or another"      | -n followed by a layout name in speech marks if it has spaces

Followed by either:

-s  | --servers | "apache01 mysql[02-05][a-j] gateway(a|b)[01-02] oracle02"     | must be in speech marks if regex input.
  This will connect to initial server of apache01 then also connect to mysql02 to 05 a j so mysql02a - mysql05-j every combination
 followed by gatewaya01 gatewaya01 gatewaya02 gatewayb01 gatewayb02 finally oracle02

You may use round brackets to look for either pattern and square brackets for wild card such as d-h or 5-10 which it will then go through this loop

-f  | --file [./mail.txt]                       | where mail.txt contains list of mail servers

Typical file could be single server names or like above brace expansion / regex :
one server per line it can be either something like:

mail01

mysql-(lon|gla)-[01-03]

where it will connect to simple host as well as match all hosts of mysql-lon-01 mysql-gla-01 mysql-lon-02 mysql-gla-02 mysql-lon-03 mysql-gla-03

Usage: termssh [-h {for help}] | [-c {connect to existing layouts} ] | [-d {delete existing layout} ]

Usage: termssh [-l {for list servers} followed by prod/stage/uat atjmo app1 app2 app3 app4 app5 app6 ]

Usage: termssh [-r remove layout and recreate ] [-fs {fullscreen mode} ] [-w {windows} 2/4/8] [-n "my file_layout name"] [-f {for file} filename ]

Usage: termssh [-r remove layout and recreate ] [-fs {fullscreen mode} ] [-w {windows} 2/4/8] [-n "my ad_layout name"]

Usage: termssh [-r remove layout and recreate ] [-fs {fullscreen mode} ] [-w {windows} 2/4/8] [-n "my input_layout name"] [-s {"server1 server[2-3] (web|gateway)[01-03]asd" }

Command Line Input CLI connect example:

EXAMPLE 1: termssh -fs -x 2 -w 8 -n custom_server1 -s "(apache|mysql)-[01-03][a-b] gateway[01-03]" {Fullscreen mode, 8 windows per tab connect twice per server brace expand patterns and connect to

apache01a apache01b mysql01a mysql01b ... mysql01-03a/b servers as well as gateway01 gateway02 gateway03 set the layout name to custom_server1 for reconnection

EXAMPLE 2: termssh -r -w 2 -x 3 -s montct01,monapa01 {Remove layout 2 windows per tab X 3 comma seperated list i.e. 3 times to monstct01 and 3 times to monsapa01 2 per tab = 3 tabs }

File connect example:

EXAMPLE 3: termssh -w 8 -f ./servers.txt {Go through servers.txt and connect to all with 8 windows per tab }

EXAMPLE 4: termssh -r -w 8 -f ./servers.txt {Remove layout go through file and connect 8 windows per tab}

Existing Layout connection:

EXAMPLE 9: termssh -c {List existing layouts and give u numeric option to connect to them}

Removal of existing layout:

EXAMPLE 10: termssh -d {List existing layouts and give u numeric option to remove 1}

repository: nean-and-i/termssh

repo_name: nean-and-i/termssh


text:
# Note

The DXF files are suitable laser cutting parts using 3mm materials

# Warning

By mounting the PCB in this frame, the high voltage anode pins will be exposed at the rear.

If using this design, the clock should be placed in a safe area / display cabinet.

![frame](https://github.com/hansj66/NixieKit/blob/master/enclosures/alternative1/IN_12_kit_frame.png)


text:
# dockerfiles

A collection of curated dockefiles used to develop great software at the [IT'IS Foundation](https://itis.swiss/)

## Why?

During our development workflow we use a great variety of thirdparty software tools (e.g. compilers, debuggers, package managers, ...) or services (e.g. CI services, artifacts repositories, monitoring services, ...) . Each of these have a very specific setup and version which is tuned to our needs at that point in time. Encapsulating all these tools in containers allows us to *snapshot* the tool/service and using it anytime without having to deal with tedious installation  following some wiki step-by-step instructions.

This repo keeps a curated list of dockerfiles that are continuously deployed into our public [itis-dockerhub] repo.

## Usage

#### Running tools

```command line
$ docker run -it itisfoundation/pip-kit --help
```

#### Developing

```command line
$make help
all – Builds all images
build – Builds all images
clean – Cleans all unversioned files in project
help – Display all callable targets
```

## Guidelines

Here some of the guidelines we have collected so far:

1. Every container MUST be defined on its own folder and in a ``Dockerfile``
   1. ``Dockerfile``s SHALL be written following [best practices](https://docs.docker.com/develop/develop-images/dockerfile_best-practices/)
2. Every image MUST include some of the labels defined in [label-schema.org](http://label-schema.org/rc1/)
3. One of the image names MUST be formatted as ``itisfoundation/${folder-name}:${tag}``
4. Every image MUST build from ``make build`` (see [docker-compose](docker-compose.yaml))
5. Containers SHALL not address many applications at once
   1. One application per container is the prefered setup. E.g. the ``cookiecutter`` containers runs the application with the same name
   2. If this is not the case, they SHALL be refered as toolkits. For instance, ``pip-kit`` is a container with several python package management tools that can run with many applications, namely ``pip-sync``, ``pip-compile``, ``pipdeptree`` and ``pipreqs``
6. Containers SHALL run with a non-root user (see trick with ``entrypoint.sh``)
7. All containers with mounted volumes MUST run using the same uid as the host.
8. ... (add here your suggestion)

<!--- REFERENCES ---->
[itis-dockerhub]:https://hub.docker.com/u/itisfoundation

repository: oetiker/dockerfiles

gha_language: Makefile

repo_name: oetiker/dockerfiles


text:
# Spirosphaera verruculosa Abdullah, Y. Horie & Udagawa, 1986 SPECIES

#### Status
ACCEPTED

#### According to
The Catalogue of Life, 3rd January 2011

#### Published in
Nova Hedwigia 43(3-4): 508 (1986)

#### Original name
Spirosphaera verruculosa Abdullah, Y. Horie & Udagawa, 1986

### Remarks
null

repository: mdoering/backbone

repo_name: mdoering/backbone


text:
# Theme Middleware
Support themes middleware that allows to switch between themes. It is generally designed
for Zend Expressive.

## Installation

`composer require atukai/theme-middleware`

## Usage

**Zend Expressive**:

Include config from ConfigProvider.php. Recommend to use [Expressive Configuration Manager]
(https://github.com/mtymek/expressive-config-manager)

```php
$configManager = new ConfigManager([
    ...,
    \At\Theme\ConfigProvider::class,
]);
```

Create themes folder.

```php
./themes
```

Configure your settings.

```php
'themes' => [
    'theme_paths' => [
         __DIR__ . '/../themes/'
    ],
];
```

**Other frameworks**:

You should implement `Zend\Expressive\Template\TemplateRendererInterface` and
put it under `TemplateRendererInterface::class` key into your container

## Resolvers
It uses resolvers to detect theme name that should be currently used for rendering.
By default the `At\Theme\Resolver\ConfigurationResolver` is used to get theme specified in config.
You can add one or more resolvers with priority.

```php
'themes' => [
    'paths' => [
         __DIR__ . '/../themes/'
    ],
    'default_theme' => 'default',
    'resolvers' => [
        \At\Theme\Resolver\HttpRequestResolver::class => 20,
    ],
];
```

## Assets

```php
'themes' => [
    'paths' => [
         __DIR__ . '/../themes/'
    ],
    'default_theme' => 'default',
    'resolvers' => [
        \At\Theme\Resolver\HttpRequestResolver::class => 20,
    ],
    'assets' => [
        'paths' => [__DIR__ . '/../themes/default/assets'],
        'cache_dir' => __DIR__ . '/../public'
    ]
];
```

repository: atukai/theme-middleware

repo_name: atukai/theme-middleware


text:
# Hierarchical Multi-Label Text Classification

This repository is my research project, and it is accepted by CIKM'19. The [paper](https://dl.acm.org/citation.cfm?id=3357384.3357885) is already published.

The main objective of the project is to solve the hierarchical multi-label text classification (**HMTC**) problem. Different from the multi-label text classification, HMTC assigns each instance (object) into multiple categories and these categories are stored in a hierarchy structure, is a fundamental but challenging task of numerous applications.

## Requirements

- Python 3.6
- Tensorflow 1.10 +
- Numpy
- Gensim

## Introduction

Many real-world applications organize data in a hierarchical structure, where classes are specialized into subclasses or grouped into superclasses. For example, an electronic document (e.g. web-pages, digital libraries, patents and e-mails) is associated with multiple categories and all these categories are stored hierarchically in a **tree** or **Direct Acyclic Graph (DAG)**.

It provides an elegant way to show the characteristics of data and a multi-dimensional perspective to tackle the classification problem via hierarchy structure.

![](https://farm8.staticflickr.com/7806/31717892987_e2e851eaaf_o.png)

The Figure shows an example of predefined labels in hierarchical multi-label classification of documents in patent texts.

- Documents are shown as colored rectangles, labels as rounded rectangles.
- Circles in the rounded rectangles indicate that the corresponding document has been assigned the label.
- Arrows indicate a hierarchical structure between labels.

## Data

See data format in `data` folder which including the data sample files.

### Text Segment

You can use `jieba` package if you are going to deal with the Chinese text data.

### Data Format

This repository can be used in other datasets (text classification) in two ways:
1. Modify your datasets into the same format of the sample.
2. Modify the data preprocess code in `data_helpers.py`.

Anyway, it should depend on what your data and task are.

### Pre-trained Word Vectors

You can pre-training your word vectors(based on your corpus) in many ways:
- Use `gensim` package to pre-train data.
- Use `glove` tools to pre-train data.
- Even can use a **fasttext** network to pre-train data.

## Network Structure

![](https://live.staticflickr.com/65535/48647692206_2e5e6e7f13_o.png)

## Reference

**If you want to follow the paper or utilize the code, please note the following info in your work:**

> @inproceedings{huang2019hierarchical,
>
> title={Hierarchical Multi-label Text Classification: An Attention-based Recurrent Network Approach},
>
> author={Huang, Wei and Chen, Enhong and Liu, Qi and Chen, Yuying and Huang, Zai and Liu, Yang and Zhao, Zhou and Zhang, Dan and Wang, Shijin},
>
> booktitle={Proceedings of the 28th ACM International Conference on Information and Knowledge Management},
>
> pages={1051--1060},
>
> year={2019},
>
> organization={ACM}
> }

---

## About Me

黄威，Randolph

SCU SE Bachelor; USTC CS Master

Email<EMAIL_ADDRESS>
My Blog: [randolph.pro](http://randolph.pro)

LinkedIn: [randolph's linkedin](https://www.linkedin.com/in/randolph-%E9%BB%84%E5%A8%81/)


text:
### [CVE-2018-10223](https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-10223)
![](https://img.shields.io/static/v1?label=Product&message=n%2Fa&color=blue)
![](https://img.shields.io/static/v1?label=Version&message=n%2Fa&color=blue)
![](https://img.shields.io/static/v1?label=Vulnerability&message=n%2Fa&color=brighgreen)

### Description

An issue was discovered in YzmCMS 3.8. There is a CSRF vulnerability that can add an admin account via /index.php/admin/admin_manage/add.html.

### POC

#### Reference
- https://github.com/yzmcms/yzmcms/issues/1

#### Github
No PoCs found on GitHub currently.

repository: trickest/cve

repo_name: trickest/cve


text:
---
id: 32765
title: 'Thanks for an amazing 2015 #CodeAcross!'
date: 2015-02-23T12:36:25+00:00
author: Hannah Young
layout: post
guid: http://www.codeforamerica.org/blog/?p=32765
permalink: /2015/02/23/thanks-for-an-amazing-2015-codeacross/
categories:
  - News
---

    CodeAcross Miami celebrates #CodeAcross photo thanks to Damon Davidson, @wynmaestro

This past weekend, 60 communities around the world came together to [CodeAcross](http://www.codeforamerica.org/events/codeacross-2015/).

To everyone who came out to participate — **thank you!**

In just 72 hours, we saw #CodeAcross participants evaluate [175 local digital services](https://service-census.herokuapp.com/), [launch open data portals](https://twitter.com/zoeblumenfeld/status/569146751267024897), [build prototypes](https://twitter.com/mheadd/status/569631586074923009), [brainstorm on neighborhood revitalization](https://twitter.com/hypepotamus/status/567756684072742913)…and much more.

We’re just starting to sift through the report-outs from the weekend (stay tuned for a full debrief soon).

Until then, check out some press coverage:

  * Code for Boston in BizJournal
  * Code for Birmingham on Alabama.com
  * New River City in Collegiate Times
  * Code for Miami in [The Miami Times](http://miamitimesonline.com/news/2015/feb/25/hackathon-promotes-coding-and-civic-ideas/)
  * Vallejo Fellowship team in [Times Herald](http://www.timesheraldonline.com/general-news/20150221/code-for-america-fellows-meet-and-greet-vallejo)
  * Code for Boston in [Boston Business Journal](http://www.bizjournals.com/boston/blog/techflash/2015/02/will-this-weekend-civic-hackathon-at-mit-solve.html?page=all)
  * Code for Tulsa worked on Food on the Move
  * Code for Boulder on [Boulder Channel 8 News](https://vimeo.com/120843620)

And browse our Storify for a glimpse at what happened over the weekend.

    [View the story "CodeAcross 2015" on Storify]

* * *

  [View the story "CodeAcross 2015" on Storify]


text:
@47ng/check-env

[![NPM](https://img.shields.io/npm/v/@47ng/check-env?color=red)](https://www.npmjs.com/package/@47ng/check-env)
[![MIT License](https://img.shields.io/github/license/47ng/check-env.svg?color=blue)](https://github.com/47ng/check-env/blob/next/LICENSE)
[![CI/CD](https://github.com/47ng/check-env/workflows/CI%2FCD/badge.svg?branch=next)](https://github.com/47ng/check-env/actions)
[![Coverage Status](https://coveralls.io/repos/github/47ng/check-env/badge.svg?branch=next)](https://coveralls.io/github/47ng/check-env?branch=next)

  Check that the critical environment variables are set for your app,
  and that you did not leave dangerous development overrides in production.

## Installation

```
yarn add @47ng/check-env
```

## Usage

```js
import { checkEnv } from '@47ng/check-env'

checkEnv({
  // Will log an error and throw if any of these are missing:
  required: [
    'SOME_API_SECRET',
    'PRIVATE_TOKEN',
    'SOME_OTHER_IMPORTANT_THING'
    // ...
  ],

  // Will log an error and throw if any of these are set in production:
  unsafe: [
    'LOCAL_OVERRIDE_DISABLE_HTTPS',
    'INSECURE_COOKIES'
    // ...
  ]
})
```

If some required environment variable are not set, it will tell you and throw
an error at the end:
!["CLI output"](output.png)

## Error handling

You can choose to skip throwing an error with the `noThrow` option:

```js
checkEnv({
  noThrow: true,
  ...
})
```

## Conditional Checks

If you want to require some variables only in production, you can add a condition
before the variable name, any falsy value will be ignored:

```ts
const __PROD__ = process.env.NODE_ENV === 'production'

checkEnv({
  required: [
    'ALWAYS_REQUIRED',
    __PROD__ && 'ONLY_REQUIRED_IN_PRODUCTION',
    !__PROD__ && 'YOU_GET_THE_IDEA'
  ]
})
```

## Logging

By default, `check-env` uses `console.err` with emoji.

You can override the default logging methods with `logMissing` and `logUnsafe`.

Example using [Pino](https://github.com/pinojs/pino):

```js
const logger = require('pino')()

checkEnv({
  logMissing: name => logger.error(`Missing required environment variable ${name}`),
  logUnsafe: name => logger.warn(`Unsafe environment variable ${name} set in production`),
  ...
})
```

## License

[MIT](https://github.com/47ng/check-env/blob/master/LICENSE) - Made with ❤ by [François Best](https://francoisbest.com)

Using this package at work ? [Sponsor me](https://github.com/sponsors/franky47) to help with support and maintenance.

branch_name: refs/heads/next

gha_language: TypeScript


text:
---
layout: post
title: "EvalAI: Towards Better Evaluation Systems for AI Agents"
date: 2019-02-10 10:34:54
categories: arXiv_AI
tags: arXiv_AI GAN
author: Deshraj Yadav, Rishabh Jain, Harsh Agrawal, Prithvijit Chattopadhyay, Taranjeet Singh, Akash Jain, Shiv Baran Singh, Stefan Lee, Dhruv Batra
mathjax: true
---

* content
{:toc}

##### Abstract
We introduce EvalAI, an open source platform for evaluating and comparing machine learning (ML) and artificial intelligence algorithms (AI) at scale. EvalAI is built to provide a scalable solution to the research community to fulfill the critical need of evaluating machine learning models and agents acting in an environment against annotations or with a human-in-the-loop. This will help researchers, students, and data scientists to create, collaborate, and participate in AI challenges organized around the globe. By simplifying and standardizing the process of benchmarking these models, EvalAI seeks to lower the barrier to entry for participating in the global scientific effort to push the frontiers of machine learning and artificial intelligence, thereby increasing the rate of measurable progress in this domain.

##### Abstract (translated by Google)

##### URL
[http://arxiv.org/abs/1902.03570](http://arxiv.org/abs/1902.03570)

##### PDF
[http://arxiv.org/pdf/1902.03570](http://arxiv.org/pdf/1902.03570)


text:
# Rodney Reed: ‘Innocent man’ on death row due to be executed in days despite appeals to save him

Published at: **2019-11-05T12:03:45+00:00**

Author: **Chiara Giordano**

Original: [Yahoo](https://news.yahoo.com/rodney-reed-innocent-man-death-120345714.html)

A death row inmate is due to be executed within days despite new evidence suggesting he could be innocent.
Rodney Reed has been on death row in Texas for the last 21 years after he was convicted of the 1996 rape and murder of 19-year-old Stacey Stites.
The 51-year-old has always maintained his innocence but is scheduled to be executed on 20 November.
However the Innocence Project, a non-profit legal organisation that helps exonerate the wrongfully convicted, has compiled new forensic evidence and DNA samples which claim to show no signs of Reed having been at the murder scene.
Reed’s family and legal team claim he is innocent and that Ms Stites’ then-fiancé Jimmy Fennell, a former police officer and initially a person of interest in the murder case, may have been involved.
Fennell has long denied any involvement in the teenager’s murder, but he was convicted of the abduction and rape of another woman after her death and spent time in prison.
According to an affidavit submitted by Arthur Snow, who knew Fennell in prison, Fennell admitted that he had killed Ms Stites for cheating on him.
An affidavit from a former friend of both Fennell and Ms Stites says that before Ms Stites’ death Fennell had told his friend that he believed Ms Stites was “f****** a n*****.”
Another witness claims to remember Fennell saying he would murder Ms Stites if he ever caught her “messing around” on him.
The murder weapon was also allegedly never tested for DNA and three expert witnesses who testified during Reed’s initial trial have since said they made errors in their analyses.
Fennell’s lawyer, Robert Phillips, said his client had converted to Christianity since leaving prison and was helping people with drug addictions.
He added that Snow was a career criminal whose claim was not credible or in the “world of reality”.
There have been growing calls for Texas governor Greg Abbott to stay Reed’s execution.
His supporters include celebrities Rihanna and Kim Kardashian West, who tweeted the governor saying there was “substantial evidence that would exonerate” Reed, adding: “I urge you to do the right thing.”
More than 160,000 people have signed a Change.org petition asking for a stay in execution.
And Reed’s family and supporters rallied outside of the capitol building in Austin, Texas, over the weekend calling for a new trial.
The death row inmate’s brother, Rodrick Reed, told CBS Austin: “We’re just asking for what’s right.
“We’re just asking for what’s fair, and that’s all we want – so our family can be whole again.”

license: Unlicense

repository: dsadlollioygjmzvcxv/tdc-exported

repo_name: dsadlollioygjmzvcxv/tdc-exported


text:
# nginx, docker, vueJS, nodeJS
Configs and sample files for vueJS and expressJS apps running on nginx.
I collected the for me most meaningful snippets. Most of them i use in production apps or for development.

## Examples

[vueJS app with expressJS and mongoDB](https://github.com/peterklein/nginx-docker-vue-node/blob/master/examples/vuejs-nodejs-mongo)

## Config

After changing the config files run `nginx -t` to check if the syntax is ok and there are no errors. Otherwise the server will not be reloaded or restarted.

repository: peterklein/nginx-docker-vue-node

repo_name: peterklein/nginx-docker-vue-node


text:
Week 03 Assignment
==================

Your assignment for this week is to complete **one** challenge problem of your
choice within each section of the "Python for Ecologists" Data Carpentry lesson
listed below (three challenge problems total).  Your solutions to these
challenge problems should be clearly documented and contained within a single
script or Jupyter notebook, named according to our standard convention as
`jdoe.py` or `jdoe.ipynb`.

Sections from which to choose challenge problems (one each!):

1. [Combining DataFrames with
Pandas](http://datacarpentry.org/python-ecology-lesson/05-merging-data/index.html)

2.  [Data Workflows and
Automation](http://datacarpentry.org/python-ecology-lesson/06-loops-and-functions/index.html)

3. [Data Ingest & Visualization - Matplotlib &
Pandas](http://datacarpentry.org/python-ecology-lesson/08-putting-it-all-together/index.html)


text:
# R module

[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)

This repository explains how to use modules in R and provides examples and a helper function.

This is the latest iteration of the same core idea. Read my blog post ["My journey to finding R modules"](https://bobaekang.com/blog/my-journey-to-finding-r-modules/) to learn how this idea has developed into the current implementation. Also, find my previous attempt at it in [this repository](https://github.com/bobaekang/r-module-trick).

## Table of contents

* [Motivation](#motivation)
* [Using R module](#using-r-module)
  * [Getting started](#getting-started)
  * [How it works](#how-it-works)
  * [`import_module()` function](#import_module-function)
  * ["Deep" module](#deep-module)
  * [Caveats](#caveats)
* [References](#references)
* [License](#license)

## Motivation

R is a powerful and versatile tool that is great for most data analysis and data science projects. However, one of the weaknesses of R language is its lack of native support for the module pattern.

Yes, R has packages. And yes again, creating one is by no means a Herculean task, especially with the fantastic `devtools` package. Hadley Wickham, best known as the creator of popular `tidyverse`, also has written a free book, [*R Packages*](http://r-pkgs.had.co.nz/), to teach us everything about creating one! Nonetheless, in my personal experience, the convenience of quickly putting together some oft-used functionalities into a small reusable unit is still much to be desired.

To tackle this issue, a few fellow R users who are much skilled than I have already put together packages. One such package is [`modules` by Sebastian Warnholz](https://github.com/wahani/modules), which is available on CRAN. See the package vignette page [here](https://cran.r-project.org/web/packages/modules/vignettes/modulesInR.html). Another package is available at ["klmr/modules" Github repository](https://github.com/klmr/modules). The later is a rather strict translation of Python modules in R.

Here, I sought for a simple "base R" solution for implementing the module pattern. My solution is not as robust or elegant as the aforementioned alternatives. However, I am convinced that my little trick still merits any R user's consideration when it comes to simplicity and convenience.

## Using R module

### Getting started

> NOTE: Example R scripts can be found in `examples/getting-started/`

The key idea here is to evaluate the module script in a local environment to keep its values encapsulated. This involves the following two elements:

1. set `local = TRUE` when `source()`-ing a module script, and
2. evaluate it in a local environment using `local()`.

```r
# main.R

module <- local(source("module.R", local = TRUE)$value)
```

Here, simply `source()`-ing our module script will give more than what we want and we have to extract the actual module using `$value`. I'll explain this point [later](#how-it-works).

So how does a module script look like?

```r
# module.R

hello_world <- function() {
  print("Hello world!")
}

# export
list(
  hello_world = hello_world,
  greet_to = function(name) {
    print(paste0("Hi, ", name, ". Using modules in R is easy!"))
  }
)
```

The only requirement here is that the module script ends with a `list` of R functions and objects to export.

:sparkles: **And that's it!** :sparkles:

### How it works

When we "import" a module using `source()`, R evaluates the module script from top to bottom in an encapsulated, local environment and returns the last value--just as in a function. In our case, this return value is a list object, created by `list()` at the end of the script, to expose module functions and objects.

The fact that only the last value will be the return value means it is also possible to both 1) create a function or an object beforehand and then pass it to `list()` and 2) create a function or an object within the `list` call. This allows for implementing some operations that are "private", i.e. not exposed to module users.

However, as mentioned earlier, simply `source()`-ing a module script gives more than what we want. This is because `source()` returns a list containing two elements: 1) `$value`, which is the return value of the `source()`-d script, and 2) `$visible`, a boolean (logical) value for the "visibility" of the `$value`.

```r
typeof(source("module.R"))
#> [1] "list"

print(source("module.R"))
#> $value
#> $value$hello_world
#> function () {
#>   print("Hello world!")
#> }
#>
#> $value$greet_to
#> function (name) {
#>     print(paste0("Hi, ", name, ". Using modules in R is easy!"))
#>   }
#>
#>
#> $visible
#> [1] TRUE
```

Therefore, we must bind the `$value` of the `source()` output to a name to keep the actual module easily accessible. This is how we got the `main.R` code above for "importing" a module:

```r
# main.R

module <- local(source("module.R", local = TRUE)$value)

module$hello_world()
#> [1] "Hello world!"

module$greet_to("Bobae")
#> [1] "Hi, Bobae. Using modules in R is easy!"
```

:tada: **Congratulations! Now you know how to use modules in R!** :tada:

By the way, did you know that `source()` can also take a URL for its `file` argument? This means that you can `source(url)` to read a module script from a remote location, say, inside a GitHub repository. This ability to use a module script stored remotely opens up whole new possibilities!

### `import_module()` function

To make it easier to use R modules, this repository offers a helper function called `import_module()`. To use `import_module()`, first `source()` the `import_module.R` file in this repository.

> NOTE: `https://tinyurl.com/r-module/*` is redirected to `https://raw.githubusercontent.com/bobaekang/r-module/master/*`.

```r
# source from url
source("https://tinyurl.com/r-module/import_module.R")
```

This adds to the global environment the following two functions:

* `import_module(path, name, attach = FALSE, deep = FALSE, force = FALSE, quietly = FALSE)` to import an R module
* `import_module_help()` to display documentation for `import_module()`

In essense, `import_module()` is a thin wrapper over `source()` with `local()`. But it also provides the following convenience features:

* If `name` is missing (default), `import_module()` will use the R file name as the module name when attaching it to the search path or creating an object in the current environment. If `name` is provided, its value will be used.
* Setting `attach = FALSE` (default) will automatically create an R object in the current environment. Alternatively, setting `attach = TRUE` will automatically attach the module to the search path as `module:[name]`.
* Seeting `deep = TRUE` will allow `import_module()` to load a module that `source()` other R scripts inside it. This behavior is useful when using ["deep" module](#deep-module). Using `deep` is allowed for _local use only_.
* By default, to avoid overwriting existing modules and objects, `import_module()` first inspects the current environment (if `attach = FALSE`) or the search path (if `attach = TRUE`). If the module with the same name already exists, `import_module()` will return an error. You can disable this behavior by setting `force = TRUE`.
* Setting `quietly = TRUE` will prevent `import_module()` from printing a message at the end for a successful import. This behavior is useful when using ["deep" module](#deep-module).

Also see the documentation for quick reference.

```r
# see documentation for import_module
import_module_help()
```

With `import_module()`, the example above can be rewritten as follows:

```r
# main.R

source("https://tinyurl.com/r-module/import_module.R")
import_module("module.R")
#> Note: 'module' now available in the current environment

module$hello_world()
#> [1] "Hello world!"

module$greet_to("friend")
#> [1] "Hi, friend. Using modules in R is easy!"
```

To mirror the original behavior more closely, we can set `quietly = FALSE` to turn off the message. In my view, seeing the message can be helpful especially when working interactively.

We can also attach the module to the search path by setting `attach = TRUE`.

```r
# main.R

source("https://tinyurl.com/r-module/import_module.R")
import_module("module.R", attach = TRUE)
#> Note: 'module' now attached as 'module:module'

hello_world()
#> [1] "Hello world!"

greet_to("friend")
#> [1] "Hi, friend. Using modules in R is easy!"
```

### "Deep" module

> NOTE: Example R scripts can be found in `examples/deep-module/`

We can push this trick a little further to get a "deep" R module that is hierarchically structured and consists of submodules.

Let's say we have a module folder `greet/` with the following file structure:

```
greet/
        main.R
        hello_world.R
        greet_to.R
```

Here, `greet/hello_world.R` and `greet/greet_to.R` contain module functions.

```r
# greet/hello_world.R

function() {
  print("Hello world!")
}
```

```r
# greet/greet_to.R

function(name) {
  print(paste0("Hi, ", name, ". Using modules in R is easy!"))
}
```

Note that here we do not create a `list` to export since each script only has one default function to export.

Now, on the other hand, `greet/main.R` serves as a module entrypoint script. Using `import_module()`, we can register module functions into `greet/main.R`.

```r
# greet/main.R

# import submodules
import_module("hello_world.R", quietly = TRUE)
import_module("greet_to.R", quietly = TRUE)

# export
list(
  hello_world = hello_world,
  greet_to = greet_to
)
```

The choice of calling this entrypoint script `main.R` is arbitrary. Since R module is not a built-in language feature, the name of an entrypoint script is ultimately irrelevant. We can name it `init.R` following Python or `index.R` as in JavaScript. In any case, it would be a good practice to choose one and stick to it.

Now that the module is ready, we can import and use it outside `greet/`. With `import_module()`, this looks like the following:

```r
# main.R

source("https://tinyurl.com/r-module/import_module.R")

import_module("greet/main.R", deep = TRUE)
#> Note: 'greet' now available in the current environment

greet$hello_world()
#> [1] "Hello world!"
```

Note that `import_module()` is smart enough to use the module directory name as the module name. This is only the default behavior and we can override it with `name` argument if needed.

We can push this even further to create a module that contains submodules that has submodules... Here is a possible structure of such a "deep" module, adapted from [Python documentation on packages](https://docs.python.org/3/tutorial/modules.html#packages):

```
sound/                        Top level module directory
        main.R                Top-level module entrypoint
        formats/              Submodule directory for file format conversions
                main.R        Submodule entrypoint
                wavread.R
                wavwrite.R
                aiffread.R
                aiffwrite.R
                auread.R
                auwrite.R
                ...
        effects/              Submodule directory for sound effects
                main.R        Submodule entrypoint
                echo.R
                surround.R
                reverse.R
                ...
        filters/              Submodule directory for filters
                main.R        Submodule entrypoint
                equalizer.R
                vocoder.R
                karaoke.R
                ...
```

Please note that "deep" R module can be used without relying on `import_module()` since `import_module()` is only a thin wrapper over `source()` with `local()`. I will leave how to you.

### Caveats

1. Clearly, R module as presented in this repository is *not* a replacement for full-fledged R package. Apart from the fact that there is no binary installation of a module, for instance, there is no easy way to add vignettes to module or documentation to its contents that can be accessed with `help()` or `?`.

2. If you are importing external packages within your module script, please note that the package will be also attached in the main script's global environment as you "import" the module script. Consider the implications of this behavior and revise your module script accordingly as needed.

3. Using a "deep" module hosted remotely can be difficult since reletive paths in remote scripts no longer makes much sense. For this reason, `import_module()` only supports local "deep" modules.

4. R module introduced here is ultimately a *trick*. Use it as you deem fit. However, if you are looking for a more robust and elaborate solution, check out existing packages designed to support the module pattern in R or simply create your own package.

## References

* ["klmr/modules" package Github repository](https://github.com/klmr/modules)
* [*R Packages*](http://r-pkgs.had.co.nz/) by Hadley Wickham
* ["wahani/modules" package Github repository](https://github.com/wahani/modules)

## License

[MIT](http://opensource.org/licenses/MIT)

Copyright (c) 2019 Bobae Kang

repository: bobaekang/r-module

repo_name: bobaekang/r-module


text:
![logo](https://pactumjs.github.io/_media/logo-icon-small.svg)

# PactumJS

![Build](https://github.com/pactumjs/pactum/workflows/Build/badge.svg?branch=master)
![Coverage](https://img.shields.io/codeclimate/coverage/ASaiAnudeep/pactum)
![Downloads](https://img.shields.io/npm/dt/pactum)
![Size](https://img.shields.io/bundlephobia/minzip/pactum)
![Platform](https://img.shields.io/node/v/pactum)

[![Stars](https://img.shields.io/github/stars/pactumjs/pactum?style=social)](https://github.com/pactumjs/pactum/stargazers)
[![Twitter](https://img.shields.io/twitter/follow/pactumjs?label=Follow&style=social)](https://twitter.com/pactumjs)

#### REST API Testing Tool for all levels in a Test Pyramid

**PactumJS** is a REST API Testing Tool used to automate e2e, integration, contract & component (*or service level*) tests.

- ⚡ Swift
- 🎈 Lightweight
- 🚀 Simple & Powerful
- 🛠 Compelling Mock Server
- 💎 Elegant Data Management
- 🔧 Extendable & Customizable
- 📚 Clear & Comprehensive Testing Style
- 🔗 Component, Contract & E2E testing of APIs

![----------](https://raw.githubusercontent.com/pactumjs/pactum/master/assets/rainbow.png)

## Documentation

This readme offers an basic introduction to the library. Head over to the full documentation at https://pactumjs.github.io

- [API Testing](https://pactumjs.github.io/#/api-testing)
- [Integration Testing](https://pactumjs.github.io/#/integration-testing)
- [Component Testing](https://pactumjs.github.io/#/component-testing)
- [Contract Testing](https://pactumjs.github.io/#/contract-testing)
- [E2E Testing](https://pactumjs.github.io/#/e2e-testing)
- [Mock Server](https://pactumjs.github.io/#/mock-server)

## Need Help

We use Github [Discussions](https://github.com/pactumjs/pactum/discussions) to receive feedback, discuss ideas & answer questions.

## Installation

```shell
# install pactum as a dev dependency
npm install --save-dev pactum

# install a test runner to run pactum tests
# mocha / jest / cucumber
npm install --save-dev mocha
```

![----------](https://raw.githubusercontent.com/pactumjs/pactum/master/assets/rainbow.png)

# Usage

**pactum** can be used for all levels of testing in a test pyramid. It can also act as an standalone mock server to generate contracts for contract testing.

## API Testing

Tests in **pactum** are clear and comprehensive. It uses numerous descriptive methods to build your requests and expectations.

### Simple Test Cases

#### Using Mocha

Running simple api test expectations.

```js
const pactum = require('pactum');

it('should be a teapot', async () => {
  await pactum.spec()
    .get('http://httpbin.org/status/418')
    .expectStatus(418);
});

it('should save a new user', async () => {
  await pactum.spec()
    .post('https://jsonplaceholder.typicode.com/users')
    .withHeaders('Authorization', 'Basic xxxx')
    .withJson({
      name: 'bolt',
      email<EMAIL_ADDRESS>    })
    .expectStatus(200);
});
```

```shell
# mocha is a test framework to execute test cases
mocha /path/to/test
```

#### Using Cucumber

See [pactum-cucumber-boilerplate](https://github.com/pactumjs/pactum-cucumber-boilerplate) for more details on pactum & cucumber integration.

```gherkin
Scenario: Check Tea Pot
  Given I make a GET request to "http://httpbin.org/status/418"
  When I receive a response
  Then response should have a status 418
```

```js
// steps.js
const pactum = require('pactum');
const { Given, When, Then, Before } = require('@cucumber/cucumber');

let spec = pactum.spec();

Before(() => { spec = pactum.spec(); });

Given('I make a GET request to {string}', function (url) {
  spec.get(url);
});

When('I receive a response', async function () {
  await spec.toss();
});

Then('response should have a status {int}', async function (code) {
  spec.response().should.have.status(code);
});
```

## Mock Server

**pactum** can act as a standalone *mock server* that allows us to mock any server via HTTP or HTTPS, such as a REST endpoint. Simply it is a simulator for HTTP-based APIs.

Running **pactum** as a standalone *mock server*.

```js
const { mock } = require('pactum');

mock.addInteraction({
  request: {
    method: 'GET',
    path: '/api/projects'
  },
  response: {
    status: 200,
    body: [
      {
        id: 'project-id',
        name: 'project-name'
      }
    ]
  }
});

mock.start(3000);
```

![----------](https://raw.githubusercontent.com/pactumjs/pactum/master/assets/rainbow.png)

# Notes

Inspired from [frisby](https://docs.frisbyjs.com/) and [pact](https://docs.pact.io).

## Support

Like this project! Star it on [Github](https://github.com/pactumjs/pactum/stargazers) and follow on [Twitter](https://twitter.com/pactumjs). Your support means a lot to us.

## Contributors

If you've ever wanted to contribute to open source, and a great cause, now is your chance! See the [contributing docs](https://github.com/pactumjs/pactum/blob/master/CONTRIBUTING.md) for more information.

Thanks to all the people who contribute.

repository: Walrusv/cucumber-tags-issue

repo_name: Walrusv/cucumber-tags-issue