<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="generator" content="NiReports: https://www.nipreps.org/" />
<title>sub-57_ses-01_task-piper_run-01_bold :: MRIQC's BOLD fMRI report</title>
<script src="https://code.jquery.com/jquery-3.6.0.min.js" integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=" crossorigin="anonymous"></script>
<link href="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-rbsA2VBKQhggwzxH7pPCaAqO46MgnOM80zW1RWuH61DGLwZJEdK2Kadq2F9CUG65" crossorigin="anonymous">
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.2.3/dist/js/bootstrap.bundle.min.js" integrity="sha384-kenU1KFdBIe4zVF0s0G1M5b4hcpxyD9F7jL+jjXkk+Q2h455rYXK/7HAuoJl+0I4" crossorigin="anonymous"></script>

<script>
var timestamp = Date.now()

function read_form() {
    var ds = "<unset>";
    var sub = "sub-57_ses-01_task-piper_run-01_bold.nii.gz";

    var artifacts = [];
    $('#qcartifacts-group input:checked').each(function() {
        artifacts.push($(this).attr('name'));
    });

    var rating = $('#qcslider').val();
    var payload = {
        'dataset': ds,
        'subject': sub,
        'rating': rating,
        'artifacts': artifacts,
        'time_sec': (Date.now() - timestamp) / 1000,
        'confidence': $('#qcextra-confidence').val(),
        'comments': $('#qcextra-comments').val()
    };

    var file = new Blob([JSON.stringify(payload)], {type: 'text/json'});
    $('#btn-download').attr('href', URL.createObjectURL(file));
    $('#btn-download').attr('download', payload['dataset'] + "_" + payload['subject'] + ".json");
    return payload
};

function toggle_rating() {
    if ($('#qcrating-menu').hasClass('d-none')) {
        $('#qcrating-menu').removeClass('d-none');
        $('#qcrating-toggler').prop('checked', true);
    } else {
        $('#qcrating-menu').addClass('d-none');
        $('#qcrating-toggler').prop('checked', false);
    }
};

$(window).on('load',function(){
    var authorization = $('#btn-post').val()
    if (authorization.includes("secret_token")) {
        $('#btn-post').addClass('d-none');
    };
    timestamp = Date.now();
});

</script>
<style type="text/css">
/* The slider itself */
.slider {
  -webkit-appearance: none;  /* Override default CSS styles */
  appearance: none;
  margin-bottom: 8px;
  margin-left: 10%;
  width: 80%;
  height: 5px; /* Specified height */
  background: #d3d3d3; /* Grey background */
  outline: none; /* Remove outline */
  opacity: 0.7; /* Set transparency (for mouse-over effects on hover) */
  -webkit-transition: .2s; /* 0.2 seconds transition on hover */
  transition: opacity .2s;
}

/* Mouse-over effects */
.slider:hover {
  opacity: 1; /* Fully shown on mouse-over */
}

.slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 25px;
  height: 25px;
  border: 0;
  background: url('https://raw.githubusercontent.com/nipreps/nireports/main/assets/slider-handle.png');
  cursor: pointer;
  z-index: 2000 !important;
}

.slider::-moz-range-thumb {
  width: 25px;
  height: 25px;
  border: 0;
  background: url('https://raw.githubusercontent.com/nipreps/nireports/main/assets/slider-handle.png');
  cursor: pointer;
  z-index: 2000 !important;
}

</style>
</head>
<body style="font-family: helvetica;">
<nav class="navbar fixed-top navbar-expand-lg bg-light">
<div class="container-fluid">
<div class="collapse navbar-collapse" id="navbarSupportedContent">
    <ul class="navbar-nav me-auto mb-2 mb-lg-0">
        <li class="nav-item"><a class="nav-link" href="#Basic echo-wise reports">Basic echo-wise reports</a></li>
        <li class="nav-item"><a class="nav-link" href="#Extended echo-wise reports">Extended echo-wise reports</a></li>
        <li class="nav-item"><a class="nav-link" href="#Extended reports shared across echos">Extended reports shared across echos</a></li>
        <li class="nav-item dropdown">
            <a class="nav-link dropdown-toggle" id="navbarAbout" role="button" data-bs-toggle="dropdown" aria-expanded="false" href="#About">
            About
            </a>
            <ul class="dropdown-menu">
                <li><a class="dropdown-item" href="#errors">Errors</a></li>
                <li><a class="dropdown-item" href="#meta-about-metadata">Reproducibility and provenance information</a></li>
            </ul>
        </li>
    </ul>
</div>
</div>
<div class="d-flex flex-row-reverse">
<div class="form-check form-switch align-self-center flex-fill me-4">
<input class="form-check-input" type="checkbox" id="qcrating-toggler"></input>
<label class="form-check-label" style="width: 100pt;" for="qcrating-toggler">Rating widget</label>
</div>
</div>
</nav>
<noscript>
    <h1 class="text-danger"> The navigation menu uses Javascript. Without it this report might not work as expected </h1>
</noscript>

    <div id="Basic echo-wise reports" class="mt-5">
    <h1 class="sub-report-title pt-5 ps-4">Basic echo-wise reports</h1>
        <div id="datatype-figures_desc-stdev_run-01_session-01_subject-57_suffix-bold_task-piper" class="ps-4 pe-4 mb-2">
<h3 class="run-title mt-3">Standard deviation of signal through time</h3><p class="elem-caption">The voxel-wise standard deviation of the signal (variability along time).</p>                    <div class="reportlet">
<img class="svg-reportlet" src="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-stdev_bold.svg" style="width: 100%" />
</div>
<small>Get figure file: <a href="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-stdev_bold.svg" target="_blank">sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-stdev_bold.svg</a></small>

        </div>
        <div id="datatype-figures_desc-background_run-01_session-01_subject-57_suffix-bold_task-piper" class="ps-4 pe-4 mb-2">
<h3 class="run-title mt-3">View of the background of the voxel-wise average of the BOLD timeseries</h3><p class="elem-caption">This panel shows a mosaic enhancing the background around the head. Artifacts usually unveil themselves in the air surrounding the head, where no signal sources are present.</p>                    <div class="reportlet">
<img class="svg-reportlet" src="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-background_bold.svg" style="width: 100%" />
</div>
<small>Get figure file: <a href="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-background_bold.svg" target="_blank">sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-background_bold.svg</a></small>

        </div>
        <div id="datatype-figures_desc-zoomed_run-01_session-01_subject-57_suffix-bold_task-piper" class="ps-4 pe-4 mb-2">
<h3 class="run-title mt-3">Voxel-wise average of BOLD time-series, zoomed-in covering just the brain</h3><p class="elem-caption">This panel shows a mosaic of the brain. This mosaic is the most suitable to screen head-motion intensity inhomogeneities, global/local noise, signal leakage (for example, from the eyeballs and across the phase-encoding axis), etc.</p>                    <div class="reportlet">
<img class="svg-reportlet" src="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-zoomed_bold.svg" style="width: 100%" />
</div>
<small>Get figure file: <a href="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-zoomed_bold.svg" target="_blank">sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-zoomed_bold.svg</a></small>

        </div>
        <div id="datatype-figures_desc-carpet_run-01_session-01_subject-57_suffix-bold_task-piper" class="ps-4 pe-4 mb-2">
<h3 class="run-title mt-3">Carpetplot and nuisance signals</h3><p class="elem-caption">The so-called &laquo;carpetplot&raquo; may assist in assessing head-motion derived artifacts and respiation effects.</p>                    <div class="reportlet">
<img class="svg-reportlet" src="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-carpet_bold.svg" style="width: 100%" />
</div>
<small>Get figure file: <a href="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-carpet_bold.svg" target="_blank">sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-carpet_bold.svg</a></small>

        </div>
    </div>
    <div id="Extended echo-wise reports" class="mt-5">
    <h1 class="sub-report-title pt-5 ps-4">Extended echo-wise reports</h1>
        <div id="datatype-figures_desc-mean_run-01_session-01_subject-57_suffix-bold_task-piper" class="ps-4 pe-4 mb-2">
<h3 class="run-title mt-3">Voxel-wise average of BOLD time-series</h3><p class="elem-caption">The average signal calculated across the last axis (time).</p>                    <div class="reportlet">
<img class="svg-reportlet" src="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-mean_bold.svg" style="width: 100%" />
</div>
<small>Get figure file: <a href="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-mean_bold.svg" target="_blank">sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-mean_bold.svg</a></small>

        </div>
    </div>
    <div id="Extended reports shared across echos" class="mt-5">
    <h1 class="sub-report-title pt-5 ps-4">Extended reports shared across echos</h1>
        <div id="datatype-figures_desc-brainmask_run-01_session-01_subject-57_suffix-bold_task-piper" class="ps-4 pe-4 mb-2">
<h3 class="run-title mt-3">Brain extraction performance</h3><p class="elem-caption">Brain mask as internally extracted by MRIQC. Defects on the brainmask could indicate problematic aspects of the image quality-wise.</p>                    <div class="reportlet">
<img class="svg-reportlet" src="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-brainmask_bold.svg" style="width: 100%" />
</div>
<small>Get figure file: <a href="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-brainmask_bold.svg" target="_blank">sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-brainmask_bold.svg</a></small>

        </div>
        <div id="datatype-figures_desc-norm_run-01_session-01_subject-57_suffix-bold_task-piper" class="ps-4 pe-4 mb-2">
<h3 class="run-title mt-3">Spatial normalization of the anatomical image</h3><p class="elem-caption">This panel shows a <em>quick-and-dirty</em> nonlinear registration into the <code>MNI152NLin2009cAsym</code> template accessed with <a href="https://templateflow.org/browse" target="_blank"><em>TemplateFlow</em></a>.</p>                    <div class="reportlet">
<object class="svg-reportlet" type="image/svg+xml" data="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-norm_bold.svg" style="">
Problem loading figure sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-norm_bold.svg. If the link below works, please try reloading the report in your browser.</object>
</div>
<small>Get figure file: <a href="./sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-norm_bold.svg" target="_blank">sub-57/figures/sub-57_ses-01_task-piper_run-01_desc-norm_bold.svg</a></small>

        </div>
    </div>
    <div id="About" class="mt-5">
    <h1 class="sub-report-title pt-5 ps-4">About</h1>
        <div id="errors" class="ps-4 pe-4 mb-2">
<h2 class="sub-report-group mt-4">Errors</h2>                    <p class="alert alert-success" role="alert">No errors to report!</p>
        </div>
        <div id="meta-about-metadata" class="ps-4 pe-4 mb-2">
<h2 class="sub-report-group mt-4">Reproducibility and provenance information</h2><p class="elem-caption">Thanks for using <em>MRIQC</em>. The following information may assist in
reconstructing the provenance of the corresponding derivatives.
</p>                    <div class="accordion accordion-flush" id="about-metadata">


  <div class="accordion-item">
    <h2 class="accordion-header" id="about-metadata-0">
      <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#about-metadata-0-collapse" aria-controls="about-metadata-0-collapse">
        Provenance Information
      </button>
    </h2>
    <div id="about-metadata-0-collapse" class="accordion-collapse collapse" aria-labelledby="about-metadata-0-heading" data-bs-parent="#about-metadata-0">
      <div class="accordion-body metadata-table">
      <table id="about-metadata-table-0" class="table table-sm table-striped">
<tr><td colspan=2>Execution environment</td><td>singularity</td></tr>
<tr><td colspan=2>Input filename</td><td><BIDS root>/sub-57/ses-01/func/sub-57_ses-01_task-piper_run-01_bold.nii.gz</td></tr>
<tr><td>Versions</td><td>MRIQC</td><td>24.1.0.dev0+gd5b13cb5.d20240826</td></tr>
<tr><td>Versions</td><td>NiPype</td><td>1.8.6</td></tr>
<tr><td>Versions</td><td>TemplateFlow</td><td>24.2.0</td></tr>
<tr><td colspan=2>md5sum</td><td>1ce933ff5ae343f519510c10cf5bcbcf</td></tr>
</table>

      </div>
    </div>
  </div>


  <div class="accordion-item">
    <h2 class="accordion-header" id="about-metadata-1">
      <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#about-metadata-1-collapse" aria-controls="about-metadata-1-collapse">
        Dataset Information
      </button>
    </h2>
    <div id="about-metadata-1-collapse" class="accordion-collapse collapse" aria-labelledby="about-metadata-1-heading" data-bs-parent="#about-metadata-1">
      <div class="accordion-body metadata-table">
      <table id="about-metadata-table-1" class="table table-sm table-striped">
<tr><td colspan=2>ConversionSoftware</td><td>dcm2niix</td></tr>
<tr><td colspan=2>ConversionSoftwareVersion</td><td>v1.0.20170207</td></tr>
<tr><td colspan=2>EchoTime</td><td>0.0302</td></tr>
<tr><td colspan=2>EffectiveEchoSpacing</td><td>0.000640002</td></tr>
<tr><td colspan=2>FlipAngle</td><td>90</td></tr>
<tr><td colspan=2>ImageType</td><td>['ORIGINAL', 'PRIMARY', 'M', 'MB', 'ND', 'MOSAIC']</td></tr>
<tr><td colspan=2>MagneticFieldStrength</td><td>3</td></tr>
<tr><td colspan=2>Manufacturer</td><td>Siemens</td></tr>
<tr><td colspan=2>ManufacturersModelName</td><td>Prisma</td></tr>
<tr><td colspan=2>PhaseEncodingDirection</td><td>j-</td></tr>
<tr><td colspan=2>ProcedureStepDescription</td><td>CAMRIS_CHOP</td></tr>
<tr><td colspan=2>ProtocolName</td><td>BOLD_resting1</td></tr>
<tr><td colspan=2>RepetitionTime</td><td>2</td></tr>
<tr><td colspan=2>SliceTiming</td><td>[0, 0.08, 0.16, 0.2375, 0.3175, 0.3975, 0.475, 0.555, 0.635, 0.7125, 0.7925, 0.8725, 0.95, 1.03, 1.11, 1.1875, 1.2675, 1.3475, 1.425, 1.505, 1.585, 1.665, 1.7425, 1.8225, 1.9025, 0, 0.08, 0.16, 0.2375, 0.3175, 0.3975, 0.475, 0.555, 0.635, 0.7125, 0.7925, 0.8725, 0.95, 1.03, 1.11, 1.1875, 1.2675, 1.3475, 1.425, 1.505, 1.585, 1.665, 1.7425, 1.8225, 1.9025, 0, 0.08, 0.16, 0.2375, 0.3175, 0.3975, 0.475, 0.555, 0.635, 0.7125, 0.7925, 0.8725, 0.95, 1.03, 1.11, 1.1875, 1.2675, 1.3475, 1.425, 1.505, 1.585, 1.665, 1.7425, 1.8225, 1.9025]</td></tr>
<tr><td colspan=2>TaskName</td><td>piper</td></tr>
<tr><td>dcmmeta</td><td>affine</td><td>[[-2.0, 0.0, 0.0, 97.21099853515625], [0.0, 2.0, 0.0, -75.23500061035156], [0.0, 0.0, 2.0, -61.28810119628906], [0.0, 0.0, 0.0, 1.0]]</td></tr>
<tr><td>dcmmeta</td><td>reorient_transform</td><td>[[0.0, -1.0, 0.0, 95.0], [1.0, 0.0, 0.0, 0.0], [0.0, 0.0, 1.0, 0.0], [0.0, 0.0, 0.0, 1.0]]</td></tr>
<tr><td>dcmmeta</td><td>shape</td><td>[96, 96, 75, 150]</td></tr>
<tr><td>dcmmeta</td><td>slice_dim</td><td>2</td></tr>
<tr><td>dcmmeta</td><td>version</td><td>0.6</td></tr>
<tr><td colspan=2>time</td><td>{'samples': {'AcquisitionNumber': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150], 'AcquisitionTime': ['121659.265000', '121701.265000', '121703.265000', '121705.265000', '121707.265000', '121709.265000', '121711.265000', '121713.265000', '121715.265000', '121717.265000', '121719.265000', '121721.265000', '121723.265000', '121725.265000', '121727.265000', '121729.265000', '121731.265000', '121733.265000', '121735.265000', '121737.265000', '121739.265000', '121741.265000', '121743.265000', '121745.265000', '121747.265000', '121749.265000', '121751.265000', '121753.265000', '121755.265000', '121757.265000', '121759.265000', '121801.265000', '121803.265000', '121805.265000', '121807.265000', '121809.265000', '121811.265000', '121813.265000', '121815.265000', '121817.265000', '121819.265000', '121821.265000', '121823.265000', '121825.265000', '121827.265000', '121829.265000', '121831.265000', '121833.265000', '121835.265000', '121837.265000', '121839.265000', '121841.265000', '121843.265000', '121845.265000', '121847.265000', '121849.265000', '121851.265000', '121853.265000', '121855.265000', '121857.265000', '121859.265000', '121901.265000', '121903.265000', '121905.265000', '121907.265000', '121909.265000', '121911.265000', '121913.265000', '121915.265000', '121917.265000', '121919.265000', '121921.265000', '121923.265000', '121925.265000', '121927.265000', '121929.265000', '121931.265000', '121933.265000', '121935.265000', '121937.265000', '121939.265000', '121941.265000', '121943.265000', '121945.265000', '121947.265000', '121949.265000', '121951.265000', '121953.265000', '121955.265000', '121957.265000', '121959.265000', '122001.265000', '122003.265000', '122005.265000', '122007.265000', '122009.265000', '122011.265000', '122013.265000', '122015.265000', '122017.265000', '122019.265000', '122021.265000', '122023.265000', '122025.265000', '122027.265000', '122029.265000', '122031.265000', '122033.265000', '122035.265000', '122037.265000', '122039.265000', '122041.265000', '122043.265000', '122045.265000', '122047.265000', '122049.265000', '122051.265000', '122053.265000', '122055.265000', '122057.265000', '122059.265000', '122101.265000', '122103.265000', '122105.265000', '122107.265000', '122109.265000', '122111.265000', '122113.265000', '122115.265000', '122117.265000', '122119.265000', '122121.265000', '122123.265000', '122125.265000', '122127.265000', '122129.265000', '122131.265000', '122133.265000', '122135.265000', '122137.265000', '122139.265000', '122141.265000', '122143.265000', '122145.265000', '122147.265000', '122149.265000', '122151.265000', '122153.265000', '122155.265000', '122157.265000'], 'ContentTime': ['121702.091000', '121704.086000', '121706.086000', '121708.086000', '121710.086000', '121712.086000', '121714.087000', '121716.086000', '121718.086000', '121720.086000', '121722.086000', '121724.086000', '121726.086000', '121728.086000', '121730.086000', '121732.087000', '121734.086000', '121736.086000', '121738.086000', '121740.086000', '121742.086000', '121744.086000', '121746.086000', '121748.086000', '121750.087000', '121752.086000', '121754.086000', '121756.086000', '121758.086000', '121800.086000', '121802.086000', '121804.086000', '121806.086000', '121808.087000', '121810.086000', '121812.086000', '121814.086000', '121816.086000', '121818.086000', '121820.086000', '121822.086000', '121824.087000', '121826.086000', '121828.086000', '121830.086000', '121832.086000', '121834.086000', '121836.086000', '121838.086000', '121840.086000', '121842.107000', '121844.086000', '121846.086000', '121848.086000', '121850.086000', '121852.086000', '121854.086000', '121856.086000', '121858.086000', '121900.087000', '121902.087000', '121904.086000', '121906.086000', '121908.086000', '121910.086000', '121912.087000', '121914.086000', '121916.086000', '121918.087000', '121920.086000', '121922.086000', '121924.086000', '121926.086000', '121928.086000', '121930.086000', '121932.086000', '121934.087000', '121936.086000', '121938.086000', '121940.086000', '121942.086000', '121944.086000', '121946.086000', '121948.086000', '121950.106000', '121952.088000', '121954.086000', '121956.086000', '121958.086000', '122000.086000', '122002.086000', '122004.086000', '122006.086000', '122008.086000', '122010.087000', '122012.086000', '122014.086000', '122016.086000', '122018.086000', '122020.086000', '122022.086000', '122024.086000', '122026.087000', '122028.087000', '122030.086000', '122032.086000', '122034.086000', '122036.086000', '122038.086000', '122040.086000', '122042.086000', '122044.087000', '122046.086000', '122048.086000', '122050.086000', '122052.086000', '122054.086000', '122056.086000', '122058.086000', '122100.086000', '122102.087000', '122104.086000', '122106.086000', '122108.086000', '122110.086000', '122112.086000', '122114.086000', '122116.086000', '122118.086000', '122120.087000', '122122.086000', '122124.086000', '122126.086000', '122128.086000', '122130.086000', '122132.086000', '122134.086000', '122136.087000', '122138.087000', '122140.086000', '122142.086000', '122144.086000', '122146.086000', '122148.086000', '122150.086000', '122152.086000', '122154.087000', '122156.086000', '122158.086000', '122159.883000'], 'InstanceCreationTime': ['121702.091000', '121704.086000', '121706.086000', '121708.086000', '121710.086000', '121712.086000', '121714.087000', '121716.086000', '121718.086000', '121720.086000', '121722.086000', '121724.086000', '121726.086000', '121728.086000', '121730.086000', '121732.087000', '121734.086000', '121736.086000', '121738.086000', '121740.086000', '121742.086000', '121744.086000', '121746.086000', '121748.086000', '121750.087000', '121752.086000', '121754.086000', '121756.086000', '121758.086000', '121800.086000', '121802.086000', '121804.086000', '121806.086000', '121808.087000', '121810.086000', '121812.086000', '121814.086000', '121816.086000', '121818.086000', '121820.086000', '121822.086000', '121824.087000', '121826.086000', '121828.086000', '121830.086000', '121832.086000', '121834.086000', '121836.086000', '121838.086000', '121840.086000', '121842.107000', '121844.086000', '121846.086000', '121848.086000', '121850.086000', '121852.086000', '121854.086000', '121856.086000', '121858.086000', '121900.087000', '121902.087000', '121904.086000', '121906.086000', '121908.086000', '121910.086000', '121912.087000', '121914.086000', '121916.086000', '121918.087000', '121920.086000', '121922.086000', '121924.086000', '121926.086000', '121928.086000', '121930.086000', '121932.086000', '121934.087000', '121936.086000', '121938.086000', '121940.086000', '121942.086000', '121944.086000', '121946.086000', '121948.086000', '121950.106000', '121952.088000', '121954.086000', '121956.086000', '121958.086000', '122000.086000', '122002.086000', '122004.086000', '122006.086000', '122008.086000', '122010.087000', '122012.086000', '122014.086000', '122016.086000', '122018.086000', '122020.086000', '122022.086000', '122024.086000', '122026.087000', '122028.087000', '122030.086000', '122032.086000', '122034.086000', '122036.086000', '122038.086000', '122040.086000', '122042.086000', '122044.087000', '122046.086000', '122048.086000', '122050.086000', '122052.086000', '122054.086000', '122056.086000', '122058.086000', '122100.086000', '122102.087000', '122104.086000', '122106.086000', '122108.086000', '122110.086000', '122112.086000', '122114.086000', '122116.086000', '122118.086000', '122120.087000', '122122.086000', '122124.086000', '122126.086000', '122128.086000', '122130.086000', '122132.086000', '122134.086000', '122136.087000', '122138.087000', '122140.086000', '122142.086000', '122144.086000', '122146.086000', '122148.086000', '122150.086000', '122152.086000', '122154.087000', '122156.086000', '122158.086000', '122159.883000'], 'InstanceNumber': [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, 144, 145, 146, 147, 148, 149, 150], 'LargestImagePixelValue': [22417, 21595, 21295, 21221, 20947, 20984, 21612, 21472, 22292, 21843, 21335, 20753, 21472, 21044, 20914, 21242, 21347, 20883, 21481, 21587, 22258, 22053, 22200, 20004, 21922, 22078, 21549, 21801, 21464, 21153, 20321, 21536, 21577, 22083, 21576, 21765, 21799, 20107, 21743, 19962, 20298, 20163, 19973, 20431, 21171, 22174, 22012, 22377, 21892, 21704, 21795, 20293, 20302, 20909, 20548, 21117, 21017, 21650, 20062, 20412, 21096, 22274, 22214, 22297, 21988, 21789, 20367, 20185, 20517, 21645, 20943, 21060, 21805, 20148, 20236, 20100, 21090, 20890, 22389, 20870, 20537, 22098, 22113, 20126, 19930, 21751, 20783, 20068, 21643, 21019, 22616, 21987, 22154, 20132, 20927, 22003, 21419, 20304, 20092, 21492, 21108, 20120, 20041, 22132, 20176, 19375, 21676, 22061, 21264, 21235, 21207, 21281, 21058, 20695, 22621, 20422, 20650, 21137, 21172, 20727, 22008, 21901, 20435, 20139, 20629, 20956, 22470, 22807, 20734, 21928, 21657, 22000, 22451, 22534, 22261, 20670, 20465, 20251, 20760, 21160, 20544, 21161, 20354, 19692, 21168, 19863, 22263, 21853, 22474, 21880], 'TriggerTime': [11652.5, 13652.5, 15652.5, 17652.5, 19652.5, 21652.5, 23652.5, 25652.5, 27652.5, 29652.5, 31652.5, 33652.5, 35652.5, 37652.5, 39652.5, 41652.5, 43652.5, 45652.5, 47652.5, 49652.5, 51652.5, 53652.5, 55652.5, 57652.5, 59652.5, 61652.5, 63652.5, 65652.5, 67652.5, 69652.5, 71652.5, 73652.5, 75652.5, 77652.5, 79652.5, 81652.5, 83652.5, 85652.5, 87652.5, 89652.5, 91652.5, 93652.5, 95652.5, 97652.5, 99652.5, 101653.0, 103653.0, 105653.0, 107653.0, 109653.0, 111653.0, 113653.0, 115653.0, 117653.0, 119653.0, 121653.0, 123653.0, 125653.0, 127653.0, 129653.0, 131653.0, 133653.0, 135653.0, 137653.0, 139653.0, 141653.0, 143653.0, 145653.0, 147653.0, 149653.0, 151653.0, 153653.0, 155653.0, 157653.0, 159653.0, 161653.0, 163653.0, 165653.0, 167653.0, 169653.0, 171653.0, 173653.0, 175653.0, 177653.0, 179653.0, 181653.0, 183653.0, 185653.0, 187653.0, 189653.0, 191653.0, 193653.0, 195653.0, 197653.0, 199653.0, 201653.0, 203653.0, 205653.0, 207653.0, 209653.0, 211653.0, 213653.0, 215653.0, 217653.0, 219653.0, 221653.0, 223653.0, 225653.0, 227653.0, 229653.0, 231653.0, 233653.0, 235653.0, 237653.0, 239653.0, 241653.0, 243653.0, 245653.0, 247653.0, 249653.0, 251653.0, 253653.0, 255653.0, 257653.0, 259653.0, 261653.0, 263653.0, 265653.0, 267653.0, 269653.0, 271653.0, 273653.0, 275653.0, 277653.0, 279653.0, 281653.0, 283653.0, 285653.0, 287653.0, 289653.0, 291653.0, 293653.0, 295653.0, 297653.0, 299653.0, 301653.0, 303653.0, 305653.0, 307653.0, 309653.0], 'WindowCenter': [7759.0, 7732.0, 7745.0, 7725.0, 7716.0, 7746.0, 7743.0, 7741.0, 7758.0, 7730.0, 7731.0, 7745.0, 7741.0, 7732.0, 7736.0, 7723.0, 7731.0, 7725.0, 7720.0, 7730.0, 7755.0, 7737.0, 7749.0, 7708.0, 7740.0, 7749.0, 7731.0, 7741.0, 7730.0, 7742.0, 7737.0, 7754.0, 7775.0, 7760.0, 7733.0, 7750.0, 7730.0, 7708.0, 7750.0, 7708.0, 7717.0, 7730.0, 7721.0, 7740.0, 7755.0, 7766.0, 7781.0, 7767.0, 7740.0, 7751.0, 7748.0, 7726.0, 7740.0, 7748.0, 7739.0, 7744.0, 7723.0, 7761.0, 7719.0, 7738.0, 7769.0, 7759.0, 7740.0, 7749.0, 7738.0, 7762.0, 7738.0, 7752.0, 7762.0, 7755.0, 7738.0, 7746.0, 7742.0, 7728.0, 7732.0, 7732.0, 7756.0, 7727.0, 7758.0, 7716.0, 7726.0, 7750.0, 7737.0, 7707.0, 7723.0, 7751.0, 7725.0, 7721.0, 7753.0, 7747.0, 7769.0, 7753.0, 7750.0, 7735.0, 7748.0, 7784.0, 7746.0, 7721.0, 7734.0, 7754.0, 7743.0, 7741.0, 7763.0, 7795.0, 7736.0, 7440.0, 7171.0, 7701.0, 7649.0, 7584.0, 7537.0, 7524.0, 7513.0, 7593.0, 7692.0, 7696.0, 7694.0, 7671.0, 7640.0, 7637.0, 7663.0, 7688.0, 7681.0, 7663.0, 7684.0, 7672.0, 7685.0, 7693.0, 7684.0, 7696.0, 7687.0, 7693.0, 7703.0, 7692.0, 7693.0, 7671.0, 7663.0, 7653.0, 7683.0, 7666.0, 7661.0, 7655.0, 7601.0, 7443.0, 7832.0, 7561.0, 8092.0, 7962.0, 7797.0, 7767.0], 'WindowWidth': [16423.0, 16379.0, 16407.0, 16370.0, 16359.0, 16413.0, 16402.0, 16397.0, 16422.0, 16375.0, 16381.0, 16410.0, 16399.0, 16381.0, 16392.0, 16367.0, 16380.0, 16373.0, 16358.0, 16379.0, 16420.0, 16387.0, 16412.0, 16347.0, 16395.0, 16413.0, 16381.0, 16401.0, 16379.0, 16404.0, 16403.0, 16430.0, 16470.0, 16434.0, 16385.0, 16413.0, 16376.0, 16348.0, 16412.0, 16347.0, 16364.0, 16393.0, 16380.0, 16410.0, 16433.0, 16445.0, 16478.0, 16444.0, 16396.0, 16417.0, 16408.0, 16382.0, 16411.0, 16423.0, 16404.0, 16410.0, 16370.0, 16434.0, 16370.0, 16403.0, 16462.0, 16428.0, 16394.0, 16407.0, 16386.0, 16438.0, 16404.0, 16435.0, 16452.0, 16428.0, 16400.0, 16413.0, 16400.0, 16384.0, 16394.0, 16395.0, 16434.0, 16379.0, 16428.0, 16357.0, 16377.0, 16413.0, 16383.0, 16346.0, 16383.0, 16418.0, 16375.0, 16375.0, 16422.0, 16416.0, 16444.0, 16418.0, 16408.0, 16404.0, 16417.0, 16479.0, 16412.0, 16375.0, 16402.0, 16425.0, 16405.0, 16413.0, 16461.0, 16506.0, 16408.0, 15796.0, 15264.0, 16298.0, 16191.0, 16057.0, 15962.0, 15937.0, 15918.0, 16078.0, 16268.0, 16297.0, 16286.0, 16239.0, 16176.0, 16170.0, 16213.0, 16268.0, 16261.0, 16231.0, 16268.0, 16242.0, 16257.0, 16271.0, 16272.0, 16284.0, 16265.0, 16270.0, 16289.0, 16267.0, 16271.0, 16245.0, 16233.0, 16214.0, 16269.0, 16228.0, 16224.0, 16209.0, 16104.0, 15781.0, 16582.0, 16026.0, 17112.0, 16859.0, 16502.0, 16445.0]}, 'slices': {}}</td></tr>
</table>

      </div>
    </div>
  </div>


  <div class="accordion-item">
    <h2 class="accordion-header" id="about-metadata-2">
      <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#about-metadata-2-collapse" aria-controls="about-metadata-2-collapse">
        Extracted Image quality metrics (IQMs)
      </button>
    </h2>
    <div id="about-metadata-2-collapse" class="accordion-collapse collapse" aria-labelledby="about-metadata-2-heading" data-bs-parent="#about-metadata-2">
      <div class="accordion-body metadata-table">
      <table id="about-metadata-table-2" class="table table-sm table-striped">
<tr><td colspan=3>aor</td><td>0.027119866666666676</td></tr>
<tr><td colspan=3>aqi</td><td>0.015263684666666666</td></tr>
<tr><td colspan=3>dummy_trs</td><td>0</td></tr>
<tr><td>dvars</td><td colspan=2>nstd</td><td>53.619133597046975</td></tr>
<tr><td>dvars</td><td colspan=2>std</td><td>1.265335859865772</td></tr>
<tr><td>dvars</td><td colspan=2>vstd</td><td>1.0489318824161074</td></tr>
<tr><td colspan=3>efc</td><td>0.549</td></tr>
<tr><td colspan=3>fber</td><td>691.254</td></tr>
<tr><td>fd</td><td colspan=2>mean</td><td>0.23865762792734824</td></tr>
<tr><td>fd</td><td colspan=2>num</td><td>22</td></tr>
<tr><td>fd</td><td colspan=2>perc</td><td>14.666666666666666</td></tr>
<tr><td>fwhm</td><td colspan=2>avg</td><td>3.778495</td></tr>
<tr><td>fwhm</td><td colspan=2>x</td><td>3.65029</td></tr>
<tr><td>fwhm</td><td colspan=2>y</td><td>4.12637</td></tr>
<tr><td>fwhm</td><td colspan=2>z</td><td>3.558825</td></tr>
<tr><td colspan=3>gcor</td><td>0.0831301</td></tr>
<tr><td>gsr</td><td colspan=2>x</td><td>0.019721126183867455</td></tr>
<tr><td>gsr</td><td colspan=2>y</td><td>0.07207871228456497</td></tr>
<tr><td>size</td><td colspan=2>t</td><td>150</td></tr>
<tr><td>size</td><td colspan=2>x</td><td>96</td></tr>
<tr><td>size</td><td colspan=2>y</td><td>96</td></tr>
<tr><td>size</td><td colspan=2>z</td><td>75</td></tr>
<tr><td colspan=3>snr</td><td>2.2360472449422577</td></tr>
<tr><td>spacing</td><td colspan=2>tr</td><td>2.0</td></tr>
<tr><td>spacing</td><td colspan=2>x</td><td>2.0</td></tr>
<tr><td>spacing</td><td colspan=2>y</td><td>2.0</td></tr>
<tr><td>spacing</td><td colspan=2>z</td><td>2.0</td></tr>
<tr><td>summary</td><td>bg</td><td>k</td><td>44.6738</td></tr>
<tr><td>summary</td><td>bg</td><td>mad</td><td>69.9689</td></tr>
<tr><td>summary</td><td>bg</td><td>mean</td><td>549.5851</td></tr>
<tr><td>summary</td><td>bg</td><td>median</td><td>232.0</td></tr>
<tr><td>summary</td><td>bg</td><td>n</td><td>500213.0</td></tr>
<tr><td>summary</td><td>bg</td><td>p05</td><td>174.0</td></tr>
<tr><td>summary</td><td>bg</td><td>p95</td><td>2204.0</td></tr>
<tr><td>summary</td><td>bg</td><td>stdv</td><td>969.0088</td></tr>
<tr><td>summary</td><td>fg</td><td>k</td><td>0.3619</td></tr>
<tr><td>summary</td><td>fg</td><td>mad</td><td>2500.5867</td></tr>
<tr><td>summary</td><td>fg</td><td>mean</td><td>6464.7091</td></tr>
<tr><td>summary</td><td>fg</td><td>median</td><td>6113.0</td></tr>
<tr><td>summary</td><td>fg</td><td>n</td><td>190987.0</td></tr>
<tr><td>summary</td><td>fg</td><td>p05</td><td>2281.0</td></tr>
<tr><td>summary</td><td>fg</td><td>p95</td><td>11417.0</td></tr>
<tr><td>summary</td><td>fg</td><td>stdv</td><td>2733.8349</td></tr>
<tr><td colspan=3>tsnr</td><td>28.77466732414905</td></tr>
</table>

      </div>
    </div>
  </div>

</div>
        </div>
    </div>

<div id="qcrating-menu" class="card position-fixed d-none" style="width: 30%; top: 100px; left: 65%; max-height: 85%; overflow-y: auto;">
<div class="card-header m-0">
    Rating widget
    <button type="button" class="btn-close position-absolute top-0 end-0" aria-label="Close" id="close-qcrating-menu" onclick="toggle_rating()" style="margin: 10px 10px 0 0"></button>
</div>
<div class="card-body">
<div class="accordion">
  <div class="accordion-item">
    <h2 class="accordion-header" id="qcslider-head">
      <button class="accordion-button" type="button" data-bs-toggle="collapse" data-bs-target="#qcslider-collapse" aria-expanded="true" aria-controls="qcslider-collapse">Overall Quality Rating</button>
    </h2>
    <div id="qcslider-collapse" class="accordion-collapse collapse show" aria-labelledby="qcslider-head">
      <div class="accordion-body">
        <input type="range" min="1.0" max="4.0" step="0.05" value="2.5" id="qcslider" class="slider">
        <ul class="list-group list-group-horizontal slider-labels" style="width: 100%">
            <li class="list-group-item list-group-item-danger small" style="font-size: 0.7em; width: 25%; text-align:center">Exclude</li>
            <li class="list-group-item list-group-item-warning small" style="font-size: 0.7em; width: 25%; text-align:center">Poor</li>
            <li class="list-group-item list-group-item-primary small" style="font-size: 0.7em; width: 25%; text-align:center">Acceptable</li>
            <li class="list-group-item list-group-item-success small" style="font-size: 0.7em; width: 25%; text-align:center">Excellent</li>
        </ul>
      </div>
    </div>
  </div>

  <div class="accordion-item">
    <h2 class="accordion-header" id="qcartifacts-head">
      <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#qcartifacts-collapse" aria-expanded="false" aria-controls="qcartifacts-collapse">
        Record specific artifacts
      </button>
    </h2>
    <div id="qcartifacts-collapse" class="accordion-collapse collapse" aria-labelledby="qcartifacts-head">
      <div class="accordion-body">
        <fieldset id="qcartifacts-group" class="form-group">
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="head-motion" id="qcartifacts-item-0" />
                <label class="form-check-label" for="qcartifacts-item-0">Head motion artifacts</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="eye-spillover" id="qcartifacts-item-1" />
                <label class="form-check-label" for="qcartifacts-item-1">Eye spillover through <abbr title="phase-encoding">PE</abbr> axis</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="noneye-spillover" id="qcartifacts-item-2" />
                <label class="form-check-label" for="qcartifacts-item-2">Non-eye spillover through <abbr title="phase-encoding">PE</abbr> axis</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="coil-failure" id="qcartifacts-item-3" />
                <label class="form-check-label" for="qcartifacts-item-3">Coil failure</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="noise-global" id="qcartifacts-item-4" />
                <label class="form-check-label" for="qcartifacts-item-4">Global noise</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="noise-local" id="qcartifacts-item-5" />
                <label class="form-check-label" for="qcartifacts-item-5">Local noise</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="em-perturbation" id="qcartifacts-item-6" />
                <label class="form-check-label" for="qcartifacts-item-6"><abbr title="electromagnetic">EM</abbr> interference/perturbation</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="wrap-around" id="qcartifacts-item-7" />
                <label class="form-check-label" for="qcartifacts-item-7">Problematic <abbr title="field-of-view">FoV</abbr> prescription / wrap-around</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="ghost-aliasing" id="qcartifacts-item-8" />
                <label class="form-check-label" for="qcartifacts-item-8">Aliasing ghosts</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="ghost-other" id="qcartifacts-item-9" />
                <label class="form-check-label" for="qcartifacts-item-9">Other ghosts (for example, <abbr title="radiofrequency">RF</abbr> spoiling)</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="inu" id="qcartifacts-item-10" />
                <label class="form-check-label" for="qcartifacts-item-10">Intensity non-uniformity (B<sub>1</sub> bias)</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="field-variation" id="qcartifacts-item-11" />
                <label class="form-check-label" for="qcartifacts-item-11">Temporal B<sub>1</sub> field non-uniformity variation</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="processing" id="qcartifacts-item-12" />
                <label class="form-check-label" for="qcartifacts-item-12">Processing such as denoising, defacing or resamplings happened</label>
            </div>
            <div class="form-check form-switch small">
                <input class="form-check-input" type="checkbox" name="uncategorized" id="qcartifacts-item-13" />
                <label class="form-check-label" for="qcartifacts-item-13">Other uncategorized artifact(s)</label>
            </div>
        </fieldset>
      </div> <!-- accordion-body -->
    </div> <!-- accordion-collapse -->
  </div> <!-- accordion-item -->
  <div class="accordion-item">
    <h2 class="accordion-header" id="qcextra-head">
      <button class="accordion-button collapsed" type="button" data-bs-toggle="collapse" data-bs-target="#qcextra-collapse" aria-expanded="false" aria-controls="qcextra-collapse">
        Extra details
      </button>
    </h2>
    <div id="qcextra-collapse" class="accordion-collapse collapse" aria-labelledby="qcextra-head">
      <div class="accordion-body">
        <div class="input-group">
          <span class="input-group-text">Comments</span>
          <textarea class="form-control" aria-label="Comments" id="qcextra-comments"></textarea>
        </div>

        <p style="margin-top: 20px; font-weight: bold">Rater confidence</p>
        <input type="range" min="0.0" max="4.0" step="0.05" value="3.5" id="qcextra-confidence" class="slider" style="margin-left: 22%;width: 56%;">
        <ul class="list-group list-group-horizontal slider-labels" style="width: 100%">
            <li class="list-group-item list-group-item-warning small" style="width: 50%; text-align:center">Doubtful</li>
            <li class="list-group-item list-group-item-success bg-success text-white small" style="width: 50%; text-align:center">Confident</li>
        </ul>
       </div> <!-- accordion-body -->
    </div> <!-- accordion-collapse -->
  </div> <!-- accordion-item -->
</div>
<div style="margin-top: 10px">
<a class="btn btn-primary disabled" id="btn-download" href="">Download</a>
<button class="btn btn-primary" id="btn-post" value="8sSYVI0XjFqacEMZ8wF4" disabled>Share publicly</button>
</div>
<script type="text/javascript">
var MINIMUM_RATING_TIME = 10
$('#qcslider').on('input', function() {

    if ( (Date.now() - timestamp) / 1000 > MINIMUM_RATING_TIME) {
        $('#btn-download').removeClass('disabled');
        $('#btn-download').removeAttr('aria-disabled');
        $('#btn-post').removeAttr('disabled');
    };

    $('#qcslider-collapse .list-group-item').removeClass(function(index, classname) {
        return (classname.match(/(^|\s)bg-\S+/g) || []).join(' ');
    });
    $('#qcslider-collapse .list-group-item').removeClass(function(index, classname) {
        return (classname.match(/(^|\s)text-\S+/g) || []).join(' ');
    });

    if ( $(this).val() < 1.5 ) {
        $('#qcslider-collapse .list-group-item-danger').addClass('bg-danger text-white');
    } else if ( $(this).val() > 3.5 ) {
        $('#qcslider-collapse .list-group-item-success').addClass('bg-success text-white');
    } else if ( $(this).val() < 2.5 ) {
        $('#qcslider-collapse .list-group-item-warning').addClass('bg-warning text-dark');
    } else {
        $('#qcslider-collapse .list-group-item-primary').addClass('bg-primary text-white');
    };

    var payload = read_form();
});

$('#qcextra-confidence').on('input', function() {
    if ( (Date.now() - timestamp) / 1000 > MINIMUM_RATING_TIME) {
        $('#btn-download').removeClass('disabled');
        $('#btn-download').removeAttr('aria-disabled');
        $('#btn-post').removeAttr('disabled');
    };

    $('#qcextra-collapse .list-group-item').removeClass(function(index, classname) {
        return (classname.match(/(^|\s)bg-\S+/g) || []).join(' ');
    });
    $('#qcextra-collapse .list-group-item').removeClass(function(index, classname) {
        return (classname.match(/(^|\s)text-\S+/g) || []).join(' ');
    });

    if ( $(this).val() < 2.0 ) {
        $('#qcextra-collapse .list-group-item-warning').addClass('bg-warning text-dark');
    } else {
        $('#qcextra-collapse .list-group-item-success').addClass('bg-success text-white');
    };

    var payload = read_form();
});


$('#qcextra-comments').bind('input propertychange', function() {
    if ( (Date.now() - timestamp) / 1000 > MINIMUM_RATING_TIME) {
        $('#btn-download').removeClass('disabled');
        $('#btn-download').removeAttr('aria-disabled');
        $('#btn-post').removeAttr('disabled');
    };
});

$( '#btn-post' ).click( function() {
    var payload = read_form();
    var md5sum = "unspecified";
    var params = {
        'rating': payload['rating'],
        'md5sum': md5sum,
        'name': "",
        'comment': JSON.stringify(payload['artifacts'])
    };

    // disable development releases
    var authorization = $(this).val();
    var ratingReq = new XMLHttpRequest();
    ratingReq.open("POST", "https://mriqc.nimh.nih.gov:443/api/v1/rating");
    ratingReq.setRequestHeader("Content-Type", "application/json;charset=UTF-8");
    ratingReq.setRequestHeader("Authorization", authorization);
    ratingReq.onload = function () {
        status = ratingReq.status;
        $('#btn-post').removeClass('btn-primary');
        $('#btn-post').attr('disabled', true);
        $('#btn-post').attr('aria-disabled', true);
        $('#btn-post').prop('disabled');
        $('#btn-post').addClass('disabled');
        $('#btn-post').removeClass('active');
        if (status === "201") {
            $('#btn-post').addClass('btn-success');
            $('#btn-post').html('Posted!');
        } else {
            $('#btn-post').addClass('btn-danger');
            $('#btn-post').html('Failed');
        };
    };
    ratingReq.send(JSON.stringify(params));
});

$( 'body' ).on( 'click', '#qcartifacts-group input', function(e) {
    if ( (Date.now() - timestamp) / 1000 > MINIMUM_RATING_TIME) {
        $('#btn-download').removeClass('disabled');
        $('#btn-download').removeAttr('aria-disabled');
        $('#btn-post').removeAttr('disabled');
    };
    
    var payload = read_form();
});

$( 'body' ).on( 'click', '#qcrating-toggler', function(e) {
    toggle_rating();
});
</script>
</div>

<script type="text/javascript">
function toggle(id) {
    var element = document.getElementById(id);
    if(element.style.display == 'block')
        element.style.display = 'none';
    else
        element.style.display = 'block';
}
</script>
</body>
</html><script>{let postHeight = () => {window.parent.postMessage({frameHeight: document.documentElement.offsetHeight || document.documentElement.scrollHeight}, '*')}; window.addEventListener('load', postHeight); window.addEventListener('message', (event) => {if (event.source === window.parent && event.data.requestOffsetHeight) postHeight()});}</script>