* #8777 MultiLayerNetwork.evaluate(MultiDataSetIterator) overload Signed-off-by: Alex Black <blacka101@gmail.com> * #8768 SameDiff.equals Signed-off-by: Alex Black <blacka101@gmail.com> * #8750 shade freemarker library and switch to it in DL4J UI Signed-off-by: Alex Black <blacka101@gmail.com> * #8704 DL4J UI redirect Signed-off-by: Alex Black <blacka101@gmail.com> * #8776 RecordReaderDataSetIterator builder collectMetaData fix Signed-off-by: Alex Black <blacka101@gmail.com> * #8718 Fix DL4J doEvaluation metadata Signed-off-by: Alex Black <blacka101@gmail.com> * #8715 ArchiveUtils - Add option to not log every extracted file Signed-off-by: Alex Black <blacka101@gmail.com> * No exception for evaluations that don't support metadata Signed-off-by: Alex Black <blacka101@gmail.com> * Fixes Signed-off-by: Alex Black <blacka101@gmail.com> * #8765 CompGraph+MDS fix for SharedTrainingMaster Signed-off-by: Alex Black <blacka101@gmail.com> * small fix Signed-off-by: Alex Black <blacka101@gmail.com> * Timeout Signed-off-by: Alex Black <blacka101@gmail.com> * Ignore Signed-off-by: Alex Black <blacka101@gmail.com> * Revert freemarker shading Signed-off-by: Alex Black <blacka101@gmail.com> * Ignore Signed-off-by: Alex Black <blacka101@gmail.com>
63 lines
2.9 KiB
Java
63 lines
2.9 KiB
Java
/*******************************************************************************
|
|
* Copyright (c) 2015-2018 Skymind, Inc.
|
|
*
|
|
* This program and the accompanying materials are made available under the
|
|
* terms of the Apache License, Version 2.0 which is available at
|
|
* https://www.apache.org/licenses/LICENSE-2.0.
|
|
*
|
|
* Unless required by applicable law or agreed to in writing, software
|
|
* distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
|
|
* WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
|
|
* License for the specific language governing permissions and limitations
|
|
* under the License.
|
|
*
|
|
* SPDX-License-Identifier: Apache-2.0
|
|
******************************************************************************/
|
|
|
|
package org.deeplearning4j.ui;
|
|
|
|
import org.deeplearning4j.BaseDL4JTest;
|
|
import org.deeplearning4j.ui.api.LengthUnit;
|
|
import org.deeplearning4j.ui.components.chart.ChartHistogram;
|
|
import org.deeplearning4j.ui.components.chart.ChartLine;
|
|
import org.deeplearning4j.ui.components.chart.style.StyleChart;
|
|
import org.deeplearning4j.ui.components.table.ComponentTable;
|
|
import org.deeplearning4j.ui.components.table.style.StyleTable;
|
|
import org.deeplearning4j.ui.standalone.StaticPageUtil;
|
|
import org.junit.Ignore;
|
|
import org.junit.Test;
|
|
|
|
import java.awt.*;
|
|
|
|
/**
|
|
* Created by Alex on 2/06/2016.
|
|
*/
|
|
public class TestStandAlone extends BaseDL4JTest {
|
|
|
|
@Test
|
|
public void testStandAlone() throws Exception {
|
|
|
|
|
|
ComponentTable ct = new ComponentTable.Builder(new StyleTable.Builder().backgroundColor(Color.LIGHT_GRAY)
|
|
.columnWidths(LengthUnit.Px, 100, 100).build())
|
|
.content(new String[][] {{"First", "Second"}, {"More", "More2"}}).build();
|
|
|
|
ChartLine cl = new ChartLine.Builder("Title",
|
|
new StyleChart.Builder().axisStrokeWidth(1.0).seriesColors(Color.BLACK, Color.ORANGE)
|
|
.width(640, LengthUnit.Px).height(480, LengthUnit.Px).build())
|
|
.addSeries("First Series", new double[] {0, 1, 2, 3, 4, 5},
|
|
new double[] {10, 20, 30, 40, 50, 60})
|
|
.addSeries("Second", new double[] {0, 0.5, 1, 1.5, 2},
|
|
new double[] {5, 10, 15, 10, 5})
|
|
.build();
|
|
|
|
ChartHistogram ch = new ChartHistogram.Builder("Histogram",
|
|
new StyleChart.Builder().axisStrokeWidth(1.0).seriesColors(Color.MAGENTA)
|
|
.width(640, LengthUnit.Px).height(480, LengthUnit.Px).build()).addBin(0, 1, 1)
|
|
.addBin(1, 2, 2).addBin(2, 3, 1).build();
|
|
|
|
String s = StaticPageUtil.renderHTML(ct, cl, ch);
|
|
}
|
|
|
|
}
|