Skip to content

Instantly share code, notes, and snippets.

@tnaka78
tnaka78 / stanfordnlp_example_ja.py
Last active February 3, 2019 12:00
StanfordNLP Japanese example
import stanfordnlp
# stanfordnlp.download('ja')
nlp = stanfordnlp.Pipeline(lang='ja')
doc = nlp(u'私は自然言語処理を勉強しています。')
doc.sentences[0].print_dependencies()
@tnaka78
tnaka78 / s57.qgs
Created December 11, 2016 03:27
S-57 ENCをQGISで表示するためのプロジェクトファイル
<!DOCTYPE qgis PUBLIC 'http://mrcc.com/qgis.dtd' 'SYSTEM'>
<qgis projectname="" version="2.18.0">
<title></title>
<autotransaction active="0"/>
<evaluateDefaultValues active="0"/>
<layer-tree-group expanded="1" checked="Qt::PartiallyChecked" name="">
<customproperties/>
<layer-tree-layer expanded="1" checked="Qt::Checked" id="WRECKS20120905085501650" name="WRECKS">
<customproperties/>
</layer-tree-layer>
@tnaka78
tnaka78 / ArcGISRuntimeS57ENC.xaml
Created June 8, 2016 15:14
ArcGIS Runtime for .NETを使ってS57 ENCを表示させるサンプルコード
<Window x:Class="ArcGISRuntimeS57ENCSample.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:local="clr-namespace:ArcGISRuntimeS57ENCSample"
xmlns:esri="http://schemas.esri.com/arcgis/runtime/2013"
xmlns:hydro="clr-namespace:Esri.ArcGISRuntime.Hydrographic;assembly=Esri.ArcGISRuntime"
mc:Ignorable="d"
Title="MainWindow" Height="350" Width="525">
using System.Windows.Forms;
using System.ComponentModel.Composition;
namespace DotSpatialExample1
{
public partial class Form1 : Form
{
[Export("Shell", typeof(ContainerControl))]
private static ContainerControl Shell;
@tnaka78
tnaka78 / NTSReadShapefileExample.cs
Created October 8, 2015 16:14
NetTopologySuiteを使ってShapefileを読むプログラム
using GeoAPI.Geometries;
using NetTopologySuite.Geometries;
using NetTopologySuite.IO;
namespace NTSReadShapefileExample
{
class Program
{
static void Main(string[] args)
{
@tnaka78
tnaka78 / GSIVectorTileSimpleExample.html
Created September 6, 2015 14:41
OpenLayers 3を使って地理院ベクトルタイル(道路中心線・鉄道中心線・河川中心線)を表示させるコード
<!doctype html>
<html lang="ja">
<head>
<meta charset="UTF-8">
<link rel="stylesheet" href="http://openlayers.org/en/v3.8.2/css/ol.css" type="text/css">
<style>
.map {
width: 100%;
max-width: 600px;
height: 400px;