This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package info.pandanote.test | |
import Quaternion._ | |
object QuaternionTest { | |
def main(args: Array[String]): Unit = { | |
val a = Quaternion(-2,4,-3,3) | |
val b = Quaternion(-3,3,5,0) | |
val c = Quaternion(5,0,9,-4) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
# -*- coding: utf-8 -*- | |
# テキストファイルを1行ずつ読み込み、exoフォーマットで記述されたAviUtlの | |
# 字幕のテンプレートに挿入して、exoフォーマットで標準出力に出力するプログラム。 | |
# Copyright 2017,2018 pandanote.info (https://pandanote.info/) | |
# This program is free software: you can redistribute it and/or modify | |
# it under the terms of the GNU General Public License as published by | |
# the Free Software Foundation, either version 3 of the License, or | |
# (at your option) any later version. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[exedit] | |
width=1920 | |
height=1200 | |
rate=30 | |
scale=1 | |
length=402 | |
audio_rate=44100 | |
audio_ch=2 | |
[0] | |
start=1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package info.pandanote.szdi; | |
import java.io.File; | |
import java.io.IOException; | |
import java.io.InputStream; | |
import org.apache.commons.compress.archivers.sevenz.SevenZFile; | |
public class SevenZFileInputStream extends InputStream { | |
SevenZFile sevenZFile = null; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package info.pandanote.szdi; | |
import static org.apache.solr.handler.dataimport.DataImportHandlerException.SEVERE; | |
import static org.apache.solr.handler.dataimport.DataImportHandlerException.wrapAndThrow; | |
import java.io.File; | |
import java.io.FileInputStream; | |
import java.io.FileNotFoundException; | |
import java.io.InputStream; | |
import java.io.InputStreamReader; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="UTF-8" ?> | |
<dataConfig> | |
<dataSource type="info.pandanote.szdi.SevenZFileDataSource" basePath="${solr.install.dir}/../jawiki" | |
encoding="utf-8"/> | |
<document> | |
<entity | |
name="document" | |
processor="FileListEntityProcessor" | |
baseDir="${solr.install.dir}/../jawiki" | |
fileName=".*-solr\.7z$" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- configタグの内側に以下の記述を追加する。 --> | |
<lib dir="${solr.install.dir:../../../..}/dist/" regex="solr-dataimporthandler-\d.*\.jar" /> | |
<lib dir="${solr.install.dir:../../../..}/dist/" regex="solr-dataimporthandler-extras-\d.*\.jar" /> | |
<lib dir="${solr.install.dir:../../../..}/dist/" regex="SevenZDataImporter-\d.*\.jar" /> | |
<requestHandler name="/dataimport" startup="lazy" class="org.apache.solr.handler.dataimport.DataImportHandler"> | |
<lst name="defaults"> | |
<str name="config">dih-config.xml</str> | |
</lst> | |
</requestHandler> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package info.pandanote.normdist; | |
public class NormDistTest { | |
public double normDist(double x) { | |
if (x == 0.0) { | |
return 0.5; | |
} | |
double ax = x; | |
double deltaax = x; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$content = preg_replace('/\\\\begin\{(align|eqnarray)/','<div class="tex-equations">\\begin{$1',$content); | |
$content = preg_replace('/\\\\end\{(align|eqnarray)(\*?)\}/','\\end{$1$2}</div>',$content); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* MathJax */ | |
div.tex-equations { | |
overflow-x: auto; | |
} |