2023,江端さんの忘備録

「育児を手伝う」とか「家事を手伝う」などと、この時にあって、まだこんな『ふざけた』ことを平気でいっている、低能な男性芸能人のコメントに、腹を立てています

I am offended by the comments of lowly male entertainers who, in this day and age, are still talking about "helping with childcare" and "helping with household chores" and such "ridiculous" things.

―― 「育児は『する』もの」であり「家事は『する』もの」である

"Raising children is a 'doing' and housework is a 'doing'."

その程度の認識のない人間は、結婚はもちろん、育児に関わるべき人間ではありません。

People who do not have that level of awareness should not be involved in marriage, let alone raising children.

-----

最近の私は、世間の価値観が『2週間』で更新され続けていることを、痛感しています。

I have been acutely aware that the world's values continue to be updated in 'two weeks.'

ちょっと油断していると、世間の価値観から乖離してしまいます。

If I am not careful for a moment, I can diverge from the world's values.

ですので、私は、新聞、ニュース、その他のメディアを、頻繁にキャッチし続けるようにしています。

So, I try to keep up with the newspapers, news, and other media as often as possible.

もちろん、個人の信念や価値観(ポリシー)は、個人として持ち続ければ良いです。

Of course, you can continue to hold on to your personal beliefs and values (policies).

ただし、それは、世間との乖離を客観的に把握し続けた上で、のことです。

However, this is only after keeping an objective eye on the divergence from the public.

無知や無能だけで支えられている個人のポリシーなんぞ、私は、指を差して、罵倒して、嗤(わら)ってやります。

I will point, abuse, and sneer at any personal policy supported only by ignorance and incompetence.

-----

男性の育休に関して、私は一つの社会実証実験を提案しています。

About male maternity leave, I am proposing a social experiment.

『男性(夫)の育休休暇期間中の、女性(妻)の一定期間(例、3日~1週間)の外泊』です。

"During the husband's parental leave period, the wife stays out for a certain period (e.g., three days to 1 week)."

夫の寄与率100%の育児期間を設ける ―― これが絶対的に必要だと思います。

A period of childcare for the husband with a 100% contribution rate -- I think this is necessary.

そもそも、"育児の地獄"を体感できない人間が、"親"をかたるべきではないのです。

To begin with, a person who cannot experience the "hell of child-rearing" should not call himself a "parent."

―― この子を殺して、ぐっすり眠りたい

-----

しかし、この実証実験については、嫁さんが強い難色を示しています。

However, my wife has expressed strong reservations about this social experiment.

嫁さん:「その実証実験を実施すれは、かなり多くの幼児が"死ぬ"ことになるよ」

Wife: "If you do that experiment, many toddlers will "die."

江端:「私もそう思う。しかし、このくらいの危機感を与えないと、バカな男は、いつまでも"バカ"のままだ。だから、社会実証実験では、各種のセーフネットも併わせて準備する」

Ebata: "I agree. However, unless we give them a sense of crisis like this, stupid men will always remain stupid. Hence, we must prepare various safety nets for the social experiment."

モニタリング、コールセンタ、緊急救命派遣などを準備する必要があると思います。

We must prepare for monitoring, call centers, emergency life-saving dispatches, etc.

これらのセーフネットは、実験コストを高いものにするかもしれません。

These safety nets may make the cost of experimentation high.

しかし、「育児を手伝う」とか言っているバカに、「育児は『する』もの」であるという認識を叩き込むコストとしては、妥当なようにも思えます。

However, it seems reasonable as a cost to knock the perception that "Raising children is a 'doing' into the idiots who say they are going to "help with childcare."

この『男性(夫)の育休休暇機関中の、女性(妻)の一定期間(例、3日~1週間)の外泊』が、社会に定着すれば、セーフネットのコストも減少していく、と期待しています。

I expect the safety net cost will decrease if "during the husband's parental leave period, the wife stays out for a certain period (e.g., three days to 1 week)" becomes a common practice in society.

もう一つの可能性としては、「驚愕的な未婚率の上昇」という悪夢もありえます。

Another possibility could be the nightmare of a "startling increase in lifetime unmarried rates.

まあ、私たちが、"それ"を選ぶのであれば、粛々と、穏やかな我が国の死を受けいれるしかないでしょう。

Well, if that's what we choose, we will have to accept the death of our country solemnly and peacefully.

-----

では、現在のような育児休暇の考え方がなかった世代の、私のようなシニアはどうなるか?

So what happens to seniors like me, a generation that did not have the current concept of parental leave?

私(江端)は、逃げ得か?

Am I only gaining by running away?

いやいや、これからは、育児という概念がシニアの男に拡大すると思いますし、そうさせなければなりません。

No, I believe that childcare will expand to senior men and must be allowed to do so.

要介護フェーズに入っていない健康なシニアは、そのリソースを「育児」に向ける時代になります。

Healthy seniors who have not entered the phase of needing nursing care should direct their resources to "childcare."

娘たちの子どもの育児を、一定期間、私(江端)が一人でやる ―― 私には、その覚悟ができています。

I (Ebata) will be raising my daughters' children by myself for a certain period -- I am ready to do so.

-----

―― 私の過失で幼児を殺すことになるか、あるいは、私が育児過労で死ぬか

"My negligence will kill my toddler, or I will die from overworked childcare."

今、命をかけた、新しい育児の形が問われています。

Now, a new form of childcare is being questioned, putting life on the line.

2023,江端さんの忘備録

ドラマ「VIVANT」というのが大変人気のようだったので、ちょっと見てみました。

The drama "VIVANT" seemed to be very popular, so I took a look at it.

面白かったです。

It was interesting.

このドラマは、自衛隊の中でも、非公開で非合法の組織の暗躍を取り扱ったもの(のよう)です。

This drama deals with the darker side of the IDF, an undisclosed and illegal organization.

いわゆる、『イリーガル(非合法)』と言われているものです。

This is what is known as "ILLEGAL."

法治国家においては、どのようなものであれ、イリーガルは文字通り不法行為であり、刑罰(処罰)の対象であり、国庫からの予算は憲法違反です。

In a nation governed by the rule of law, ILLEGALs of any kind are illegal and subject to punishment (penalty), and budgeting from the national treasury violates the Constitution.

また、歴史上、このような政府の子飼いであるはずのイリーガルが、逆に、自国の政府を転覆させた事例など、山ほどあります。

History is replete with examples of cases in which the supposed child of a government, the ILLEGAL, has, on the contrary, overthrown its government.

つまるところ、イリーガルは、シビリアンコントロール(文民統制)の原則に反するものであり、一言で言えば、法治国家の敵です。

In short, ILLEGALs violate the principle of civilian control and are, in a word, enemies of the rule of law.

―― というような、シラけたことを書き込みしている人は、さすがにいないようですね(ちゃんと調べていませんが)。

No one has written something like that (I haven't appropriately checked).

まあ、『そういう非合法組織がないと、国家の運営が困るだろうな』ということは、国民もなんとなく理解していると思います。

The public somewhat understands that 'without such illegal organizations, the state would have trouble running the country.

-----

イリーガルと言えば、コミック「スケバン刑事」は、イリーガルの極とも言えるものでした。

Speaking of ILLEGALs, the comic " Sukeban Deka(Police of a female gang)" was the extreme of illegalism.

こちらは、警察組織のイリーガルです。

This is the police organization ILLEGALs.

この物語に登場する「暗闇警視」は、違法行為を承知の上で、学生をスパイとして学校に潜入させる確信犯でした。

The "Inspector Darkness" in this story was a crime of conscience who knowingly infiltrated students into the school as spies, knowing it was illegal.

そして、「スケバン刑事」である麻宮サキは、潜入、調査のみならず、銃刀法違反に問われない武器(ヨーヨー)を使って、違法暴力行為で被疑者を制圧するという、テロ行為まで認容されていました。

And Saki Asamiya, a "Sukeban Deka," was authorized not only to infiltrate and investigate but also to commit acts of terrorism, using a weapon (yo-yo), which is not charged with violating the Firearms Act, to subdue suspects in acts of illegal violence.

-----

ふと思ったのですが、もしかしたら、今なら、学校のいじめの実体把握に、警察の手先となった子どもが配備されているかもしれません。

It occurred to me that perhaps now, a child who has become a pawn of the police might be deployed to help the school identify the substance of the bullying.

それはそれで、有効かもしれませんし、正直支援したい気持ちがあります。

That may be valid, and frankly, I would support it.

まあ、それはさておき。

Well, let's put that aside.

-----

国家権力(警察)による潜入工作(や破壊工作)は、普通に行われています。

Infiltration (and sabotage) by state power (police) is standard.

これは、陰謀論ではなく、関係者(下手すると警察当局自身が)公表していることですし、裁判所の認可を受ければ、潜入工作自体は合法です。

This is not a conspiracy theory but something publicized by the people involved (and if poorly done, by the police authorities themselves), and the infiltration operation itself is legal if approved by the court.

最近では、テロを伴う左翼団体は、警察のスパイによってほぼ壊滅され尽くされましたし、反社(暴力団)なども内部の潜入やタレコミによって、全滅に向かって進められています。

Recently, leftist groups with terrorist activities have been almost destroyed by police spies, and anti-social groups (gangs) are also being advanced toward destruction by inside infiltration and tip-offs.

ただし、裁判において、潜入工作による証拠が採用できるかどうかは、不明です(ご存知の方は教えて下さい)。

However, it is unclear whether evidence from undercover operations can be adopted in a court of law (please let me know if you know).

最高の笑顔

ただ、裁判所は、「VIVANT」や「スケバン刑事」の活動を、絶対に認可しないと思います(高度な政治的圧力があれば別かもしれませんが)。

However, I don't think the courts will ever sanction the activities of "VIVANT" or "Sukeban Deka" (unless there is a high level of political pressure to do so).

-----

ともあれ、このような話は、ドラマやコミックを楽しんでいる人の横で、語ってはなりません。

Anyway, such stories should not be told besides those enjoying the drama and comics.

絶対に嫌われます。

They absolutely come to hate you.

2023,江端さんの技術メモ

pgr_dijkstra()で、ダイクストラの順番を壊さずにルートの座標を得る方法(getDijkstraPath())

ノードの切断を発生させず、ノード10~ノード20と、ノード30~ノード40を回避するダイクストラ計算を行うPostGISのクエリー

をベースとしたGo言語のプログラムになります。

// C:\Users\ebata\tomioka3B\src\others\main23.go
package main

import (
	"database/sql"
	"fmt"
	"log"
	"m/src/ldarp"
	"strconv"

	_ "github.com/lib/pq"
)

func main() {
	db, err := sql.Open("postgres",
		"user=postgres password=password host=192.168.0.23 port=15432 dbname=tomioka_db_c sslmode=disable")
	if err != nil {
		log.Fatal("OpenError: ", err)
	}
	defer db.Close()

	/*
		以下のldarp.LocInfoの内容は、
		type LocInfo struct {
			Lon    float64
			Lat    float64
			Source int
		}
		となっています。
		このプログラムファイルでは、上記を定義して、ldarp.LocInfoを、LocInfoと変換すれば動きます

		ただ、前提とするpostgresqlのpostGISが取り扱うデータベースは、
		mapconfig_for_cars.xml をベースとして構築しているものになりますので、ご留意下さい
		https://github.com/pgRouting/osm2pgrouting/blob/main/mapconfig_for_cars.xml
	*/

	var a_Point, b_Point ldarp.LocInfo

	a_Point.Source = 1  // 出発ノード
	b_Point.Source = 50 // 到着ノード

	var del_start1, del_end1, del_start2, del_end2 ldarp.LocInfo
	//var del_start3, del_end3 ldarp.LocInfo

	del_start1.Source = 10 // 1つ目の無効としたいノード番号(開始番号)
	del_end1.Source = 20   // 1つ目の無効としたいノード番号(終了番号)
	del_start2.Source = 30 // 2つ目の無効としたいノード番号(開始番号)
	del_end2.Source = 40   // 2つ目の無効としたいノード番号(開始番号)
	//del_start3.Source = 30
	//del_end3.Source = 35

	array1 := []ldarp.LocInfo{del_start1, del_end1} // 上記の無効としたいノード番号を登録する
	array2 := []ldarp.LocInfo{del_start2, del_end2} // 上記の無効としたいノード番号を登録する
	//array3 := []ldarp.LocInfo{del_start3, del_end3}

	//delSourceArray := [][]ldarp.LocInfo{array1, array2, array3}
	delSourceArray := [][]ldarp.LocInfo{array1, array2} // 登録したノード番号をarraysの変数に纏める
	//delSourceArray = [][]ldarp.LocInfo{}

	// arrays変数への挿入
	//for _, arr := range arrays {
	//	delSourceArray = append(delSourceArray, arr)
	//}

	// fmt.Println(delSourceArray)

	path, dist := getDijkstraPath(db, a_Point, b_Point, delSourceArray)

	fmt.Println("path:", path)
	fmt.Println("dist:", dist)

}

// 江端再修正版(2023/09/29)
/*
出発ノードと到着ノードと、通過したくないノード(無効したいノード)を登録して、ダイクストラ計算によるルートを選ぶ
*/

func getDijkstraPath(dbMap *sql.DB, locInfoStart, locInfoGoal ldarp.LocInfo, delSourceArray [][]ldarp.LocInfo) ([]ldarp.LocInfo, float64) {
	log.Println("getDijkstraPath", locInfoStart, locInfoGoal)

	sql_str := "" // SQL文を作る文字列の初期値

	// delSourceArray の解析
	fmt.Println("delSourceArray:", delSourceArray)

	if len(delSourceArray) != 0 { // delSourceArrayに要素が入っていれば

		// forとrangeを使用して各要素のSource値を取得
		sql_str = "WHERE "

		for _, arr := range delSourceArray {
			/*
				for _, loc := range arr {
					fmt.Printf("Sourceの値: %d\n", loc.Source)
				}
			*/
			fmt.Println(arr[0].Source, arr[1].Source)
			//str += "( source NOT BETWEEN " + arr[0].Source + " AND " + arr[1].Source + " AND target NOT BETWEEN " + arr[0].Source + " AND " + arr[1].Source + ")"
			sql_str += "(source NOT BETWEEN " + strconv.Itoa(arr[0].Source) + " AND " + strconv.Itoa(arr[1].Source) + " AND target NOT BETWEEN " + strconv.Itoa(arr[0].Source) + " AND " + strconv.Itoa(arr[1].Source) + ") AND "
			//fmt.Println(str)
		}
		strlen := len(sql_str)
		sql_str = sql_str[:strlen-5] // ラストの" AND "の5文字を削除する
		//fmt.Println(str)
	}

	sql_str = "SELECT seq,source, target, x1, y1, x2, y2, agg_cost FROM pgr_dijkstra('SELECT gid as id, source, target, cost, reverse_cost FROM ways " + sql_str + "', $1::bigint , $2::bigint , directed:=false ) a INNER JOIN ways b ON (a.edge = b.gid) ORDER BY seq"

	//fmt.Println(sql_str)

	var path []ldarp.LocInfo // 経路 (返り値の一つ目)
	var totalDistanceKm float64

	rowsDijkstra, errDijkstra := dbMap.Query(
		//"SELECT seq,source, target, x1, y1, x2, y2, agg_cost FROM pgr_dijkstra('SELECT gid as id, source, target, length_m as cost FROM ways', $1::bigint , $2::bigint , directed:=false ) a INNER JOIN ways b ON (a.edge = b.gid) ORDER BY seq",
		//"SELECT seq,source, target, x1, y1, x2, y2, agg_cost FROM pgr_dijkstra('SELECT gid as id, source, target, length_m as cost FROM ways WHERE (source NOT BETWEEN 10 AND 20 AND target NOT BETWEEN 10 AND 20) AND (source NOT BETWEEN 30 AND 40 AND target NOT BETWEEN 30 AND 40)', $1::bigint , $2::bigint , directed:=false ) a INNER JOIN ways b ON (a.edge = b.gid) ORDER BY seq",
		sql_str,
		locInfoStart.Source,
		locInfoGoal.Source)

	if errDijkstra != nil {
		log.Fatal(errDijkstra)
	}
	defer rowsDijkstra.Close()

	var agg_cost float64

	var loc ldarp.LocInfo
	var x1, y1, x2, y2 float64
	var seq int
	var target int
	var source int

	isFirstCheck := true
	isSourceCheck := true

	for rowsDijkstra.Next() {

		// まずnodeを読む
		if err := rowsDijkstra.Scan(&seq, &source, &target, &x1, &y1, &x2, &y2, &agg_cost); err != nil {
			fmt.Println(err)
		}

		// 最初の1回だけチェックのために入る これについては、https://wp.kobore.net/江端さんの技術メモ/post-7668/を参照のこと
		// もし rowsDijkstra.Scanで最初のsource値を読みとり、locInfoStart.Source の値と同じであれば、x1,y1をベースとして、異なる値であれば、x2,y2をベースとする

		if isFirstCheck {
			if source == locInfoStart.Source {
				isSourceCheck = true // x1, y1をベースとする処理になる
			} else {
				isSourceCheck = false // x2,y2をベースとする処理になる
			}
			isFirstCheck = false // 最初の1回をチェックすることで、2回目はこのループには入らなくなる
		}

		//var loc ldarp.LocInfo

		if isSourceCheck { // x1, y1をベースとする処理
			loc.Source = source
			loc.Lon = x1
			loc.Lat = y1
		} else { // x2,y2をベースとする処理
			loc.Source = target
			loc.Lon = x2
			loc.Lat = y2
		}
		path = append(path, loc)
	}

	// ラストノードだけはsourceとtargetを引っくり返す
	if isSourceCheck { // x1, y1をベースとする処理
		loc.Source = target
		loc.Lon = x2
		loc.Lat = y2
	} else { // x2,y2をベースとする処理
		loc.Source = source
		loc.Lon = x1
		loc.Lat = y1
	}

	path = append(path, loc)

	totalDistanceKm = agg_cost / 1000.0
	return path, totalDistanceKm
}

2023,江端さんの忘備録

先日、BSで、映画「十戒」が放送されていたので、録画しました。

The other day, the movie "The Ten Commandments" was broadcast on BS, and I recorded it.

江端:「『十戒』を録画しておいたので、興味があれば見て」

Ebata: "I recorded 'The Ten Commandments' for you to watch if you are interested."

嫁さん:「うーん、あまり興味ないかな」

Wife: "Hmmm, not interested."

江端:「旧約聖書を読むより、ラクに理解できるよ」

Ebata: "It's easier to understand than reading the Old Testament."

嫁さん:「なんで、旧約聖書の内容を理解しなければならないの?」

Wife: "Why do I have to understand the Old Testament?"

と言われて、「確かに、そうだ」と、納得してしまいました。

I thought, "Sure, that's right," and agreed.

日本人なら、「日本神話」の方が先だと思ったのですが、よく考えたら「いやいや、別に、それすらも必要ないだろう」と自分で、自分に突っ込んでしまいました。

I thought "Japanese mythology" would be the first thing a Japanese person would think of, but then I thought about it and said, "No, no, not really, we don't even need that either."

私は、日本の神様(天皇陛下のご先祖)が、結構「ポンコツ」だったという話が、結構好きです。

旧約聖書の内容を知っていると、トクになることって何だろうなぁ、と考えてみたのですが、現在の問題に限定すれば「パレスチナ問題」の見通しが良くなるくらいですかね。

I wondered what the benefits of knowing the contents of the Old Testament would be, and I thought that if limited to current issues, it would only improve the outlook on the "Palestinian problem."

-----

個人的には、「旧約聖書」より「新約聖書」の方が面白いです。

I find the "New Testament" more interesting than the "Old Testament".

といっても、わざわざ「新約聖書」を読む必要なんぞななくて、関連するアニメや映画やコミックで、断片的に内容を繋げれば十分だと思います。

However, reading the "New Testament" all the way through is unnecessary. It is enough to connect the contents of the New Testament with related anime, movies, and comics in bits and pieces.

そもそも、その「新約聖書」は、ナザレのイエス没300年後(西暦325年)に、編集会議(ニケーア公会議)で、その内容を、各宗派の議論と投票で決定したものです。

To begin with, the contents of the "New Testament" were decided by the editorial council (Council of Nicea) 300 years after the death of Jesus of Nazareth through discussion and voting by the various denominations.

新約聖書の編集会議は、少年ジャンプの新連載マンガを決定する、または連載打ち切りを決定する会議と、基本的に同じだったのです。

The New Testament editorial meeting was essentially the same as the meeting that decided on a new manga series for Shonen Jump or decided to discontinue the series.

まあ、そう考えていくと、ルターの宗教改革から始まったプロテスタントキリスト教や、その「聖書至上主義」も、私の心にはヒットしません。

When I think about it, Protestant Christianity and its "biblical supremacy" that began with Luther's Reformation doesn't hit me either.

―― 人間が会議で編纂した書物(新約聖書)が、「神の言葉」なんぞである訳がない

"How can a book (the New Testament) compiled by a conference of men be the "Word of God"?"

と。

カソリックキリスト教については、言うに及ばずです。

Not to mention Catholic Christianity.

ちなみに、仏教の各宗派に関しては、私は、異なる同人誌のサークルくらいの意識しか持っていません。

By the way, I know that Buddhist sects are the same as doujinshi circles.

―― ゴーダマシッダールタさん没後、2500年オーダの時間をかけて創作され続けた膨大な物量の「同人誌」

もちろん、私は、コミケサークルの活動を尊重しているくらいですから、世界中の宗教も ―― アホなカルト宗教団体や原理主義者を除けば ―― 同様に敬意を払っています。

Of course, I respect the activities of the Comic Circle so much that I appreciate all the religions of the world -- except for the idiotic cult groups and fundamentalists -- as well.

-----

『では「神学」は無意味な学問か』と問われれば、そうではないようです。

If you ask, 'Then is "theology" a meaningless discipline?' it seems not.

「神学」は、哲学でもあり、論理学でもあり、法学でもあり、見方によっては科学や数学(の証明)とも言えるもののようです。

"Theology" appears to be a philosophy, a logic, a jurisprudence, and, depending on one's point of view, a science or a mathematical (proof of) science.

私に来世があるなら、「神学」の勉強をしてみたいと思っています(現世は、ちょっと忙しすぎるようなので)。

If I have a next life, I would like to study "theology" (this life seems a bit too busy for me).

-----

「旧約」も「新約」も「日本神話」も、私たちには、別段必要ではありません。

We don't need "Old Testament," "New Testament," or "Japanese mythology.

という訳で、本日の日記は、スルーして頂いて結構です。

Therefore, you may pass through today's diary.

あなたたちの中で、不要不急の外出をしたことがない者が、政府または東京都に、まず石を投げなさい

2023,江端さんの技術メモ

C:\Users\ebata\tomioka3B\src\others\main21.goでバトル中 

tomioka_db_c=# SELECT seq, node, edge, source, target, b.cost FROM pgr_dijkstra('SELECT gid as id, source, target, cost, reverse_cost FROM ways WHERE (source NOT BETWEEN 10 AND 20 AND target NOT BETWEEN 10 AND 20) AND (source NOT BETWEEN 30 AND 40 AND target NOT BETWEEN 30 AND 40)',1, 50, directed := false) a INNER JOIN ways b ON (a.edge = b.gid) ORDER BY seq;

seq | node | edge | source | target | cost
-----+------+------+--------+--------+------------------------
1 | 1 | 2 | 1 | 2 | 8.518550262944415e-05
2 | 2 | 3 | 2 | 3 | 0.0009420518456308501
3 | 3 | 4 | 3 | 4 | 0.00026662995399998605
4 | 4 | 5 | 4 | 5 | 0.00021389117484400878
5 | 5 | 6 | 5 | 6 | 4.656362881781325e-05
6 | 6 | 7 | 6 | 7 | 0.00013184236987589488
7 | 7 | 8 | 7 | 8 | 6.438782425766514e-05
8 | 8 | 1254 | 8 | 897 | 1.2290752319372595e-05
9 | 897 | 1380 | 897 | 969 | 0.00038637624148597305
10 | 969 | 1938 | 969 | 1389 | 2.250777644883257e-05
11 | 1389 | 694 | 1389 | 542 | 0.0002978010745492113
12 | 542 | 1251 | 542 | 895 | 0.00015951582993150323
13 | 895 | 1815 | 895 | 1305 | 0.0001303909506021454
14 | 1305 | 1021 | 1305 | 753 | 3.9356066874244885e-05
15 | 753 | 1381 | 753 | 971 | 0.0002850072862639029
16 | 971 | 1382 | 976 | 971 | 0.001276712172995213
17 | 976 | 1388 | 977 | 976 | 0.0004267486614026622
18 | 977 | 1389 | 986 | 977 | 0.0006757336753520132
19 | 986 | 1404 | 906 | 986 | 0.0003707891314505199
20 | 906 | 1275 | 906 | 907 | 0.0001959266189093194
21 | 907 | 1277 | 907 | 908 | 9.052734394018332e-05
22 | 908 | 1921 | 908 | 1376 | 5.400925846418281e-05
23 | 1376 | 1279 | 1376 | 909 | 1.8504323815069496e-05
24 | 909 | 1057 | 909 | 773 | 6.840328939622445e-05
25 | 773 | 1069 | 773 | 781 | 0.000535513050350553
26 | 781 | 1071 | 781 | 784 | 0.00014276168953525706
27 | 784 | 1087 | 784 | 793 | 0.0004430493335842619
28 | 793 | 1682 | 793 | 1192 | 7.9895243915049e-05
29 | 1192 | 1111 | 1192 | 808 | 0.0005876979547862221
30 | 808 | 1125 | 808 | 816 | 0.00047564125136792903
31 | 816 | 51 | 816 | 49 | 3.10328360877585e-05
32 | 49 | 52 | 49 | 50 | 0.00028187114581170033

一応、QGISで調べて、ノード切れが発生していないことは確認しました。


新規に作ったノード182~413を、ちゃんと無視できるかの実験。ベースは以下のメモの内容。

pgr_dijkstra()で、ダイクストラの順番を壊さずにルートの座標を得る方法(getDijkstraPath())

■無視前

tomioka_db_c=# SELECT seq, source, target, x1, y1, x2, y2 FROM pgr_dijkstra('SELECT gid as id, source, target, cost, reverse_cost FROM ways',1036, 1320, directed := false) a INNER JOIN ways b ON (a.edge = b.gid) ORDER BY seq;
seq | source | target | x1 | y1 | x2 | y2
-----+--------+--------+-----------------+----------------+-----------------+----------------
1 | 1036 | 182 | 139.6295688 | 35.3660511 | 139.62956342765 | 35.36605302299
2 | 182 | 183 | 139.62956342765 | 35.36605302299 | 139.62952386387 | 35.36602637499
3 | 183 | 184 | 139.62952386387 | 35.36602637499 | 139.62949515388 | 35.36599335049
4 | 184 | 185 | 139.62949515388 | 35.36599335049 | 139.62949783814 | 35.3658805722
5 | 185 | 186 | 139.62949783814 | 35.3658805722 | 139.629505074 | 35.36583679324
6 | 186 | 187 | 139.629505074 | 35.36583679324 | 139.62955514143 | 35.36580196041
7 | 187 | 188 | 139.62955514143 | 35.36580196041 | 139.62972133265 | 35.36574533322
8 | 188 | 189 | 139.62972133265 | 35.36574533322 | 139.62969285571 | 35.3656615823
9 | 189 | 190 | 139.62969285571 | 35.3656615823 | 139.62929978548 | 35.36461811112
10 | 190 | 191 | 139.62929978548 | 35.36461811112 | 139.62923349573 | 35.3644776355
11 | 191 | 192 | 139.62923349573 | 35.3644776355 | 139.62887730502 | 35.36401128513
12 | 192 | 193 | 139.62887730502 | 35.36401128513 | 139.62881288258 | 35.36394808968
13 | 193 | 194 | 139.62881288258 | 35.36394808968 | 139.62878113819 | 35.36393552673
14 | 194 | 195 | 139.62878113819 | 35.36393552673 | 139.62874285819 | 35.36391763403
15 | 195 | 196 | 139.62874285819 | 35.36391763403 | 139.62711549003 | 35.36370406459
16 | 196 | 1320 | 139.62711549003 | 35.36370406459 | 139.6270944 | 35.3636816
(16 rows)

■無視後

tomioka_db_c=# SELECT seq, source, target, x1, y1, x2, y2 FROM pgr_dijkstra('SELECT gid as id, source, target, cost, reverse_cost FROM ways WHERE (source NOT BETWEEN 182 AND 413 AND target NOT BETWEEN 182 AND 413) AND (source NOT BETWEEN 182 AND 413 AND target NOT BETWEEN 182 AND 413)',1036, 1320, directed := false) a INNER JOIN ways b ON (a.edge = b.gid) ORDER BY seq;
seq | source | target | x1 | y1 | x2 | y2
-----+--------+--------+-------------+------------+-------------+------------
1 | 1034 | 1036 | 139.6297237 | 35.365746 | 139.6295688 | 35.3660511
2 | 1034 | 1033 | 139.6297237 | 35.365746 | 139.6297007 | 35.3656671
3 | 1033 | 1325 | 139.6297007 | 35.3656671 | 139.6287884 | 35.3639297
4 | 1325 | 1320 | 139.6287884 | 35.3639297 | 139.6270944 | 35.3636816

うん、これを見ている限りは、大丈夫そうに見える。

 

2023,江端さんの忘備録

―― 親父にもっと話を聞いておけばよかったな

"I should have talked to my dad more."

と、亡き父の事を思い出しています。

I remember my late father.

私は、今、メンタル不調が継続しています。

I am currently experiencing ongoing mental illness.

私なりの自己分析では、(1)タスクオーバーフローに加えて、(2)タスクのゴールが見えない、という恐怖に因るものが主要因です。

According to my self-analysis, the leading causes are (1) task overflow and (2) fear of not being able to see the goal of the task.

―― メンタル不調は、報告しにくい

-----

私の父は、私より少しだけ若い年齢で、木工会社を起業したのですが、私から見ても『下請けの地獄』をモロに受け続けていたと思います。

My father started his own woodworking company at an age slightly younger than me, and from my point of view, he continued to suffer the 'hell of subcontractors.'

金策、不渡り、暴力団からの恫喝、連鎖倒産、関連会社社長夫妻の自殺 ―― そこには、私などの状況とは比べるべくもない『地獄』がありました。

Money laundering, dishonoring, threats from gangsters, chain-reaction bankruptcies, and the suicides of the president of an affiliated company and his wife - there was a "hell" that could not be compared to my situation.

私から見えているだけでも、これだけの話があったのですから、もっと凄まじい『地獄』もあったはずです。

There must have been more horrendous "hells" than this since there were so many stories just from what I can see.

だから私は、安易に『起業』を叫ぶやつも、勧めるヤツも、大嫌いです。

I hate those who shout "start a business" quickly or encourage people to do so.

=====

「江端さんのDIY奮闘記 EtherCATでホームセキュリティシステムを作る(4)」より抜粋

Excerpt from "Mr. Ebata's DIY Struggle: Building a Home Security System with EtherCAT (4)

私が大学1年生の時、起業した父の木工会社が、連鎖倒産のあおりを食らいました。その倒産元の夫婦は、ヤクザに追い込まれて、息子たちを逃がした後、夫婦で自殺しました。あの時は、私も大学の退学を覚悟しました。

When I was a freshman in college, my father's woodworking company, which he had started, was hit by a chain reaction bankruptcy. The couple behind the bankruptcy were driven into a corner by the Yakuza, and after escaping their sons, they committed suicide together. At that time, I was prepared to drop out of college.

「起業家がきちんと法律通りに守られる」と信じている人は、一度、裏社会の暴力装置と、日本の自殺者の構成比率を調べることをお勧めします。

For those who believe that "entrepreneurs are properly protected according to the law," I suggest you take a moment to examine the violent apparatus of the underworld and the composition of suicides in Japan.

私が覚えている限り、単に「失敗すれば終わり」 ―― で済ましてくれるほど、世の中は優しくなかったですよ。

As far as I can remember, the world has not been so kind to us as to let us "fail and it's over."

======

私なら、これだけの『地獄』に直面すれば、メンタル不調など軽く飛び越えて、簡単に自死に至る自信があります。

I am confident that if faced with such a "hell," I would quickly jump over mental illness and commit suicide.

―― 一体、父は、どのように、このような『地獄の日々』をすごしてきたのだろうか

"How did my father go through these "hell days"? "

そんな風に思うと、『親父にもっともっと話を聞いておけばよかったな』と、物凄く貴重な人材からノウハウを聴き出せなかったことに、最大級の後悔をしています。

When I think about it like that, I have the biggest regret that I didn't get the know-how out of this precious person, saying, 'I wish I had talked to my father more and more.'

2023,江端さんの忘備録

先日、大学の学生さんとお話する機会を得ました。

I recently had the opportunity to speak with a student at the university.

江端:「データベースは、私がサクッっと作るので、SQLでクエリーでサーチして貰えれば。SQLクエリーは、結構、かん・・・」

Ebata: "I'll make the database quickly, and you can search it with SQL queries easi..."

と言いかけて、そこで、思い留まりました。

I was about to say that. However, I had to stop myself.

江端:「うん。SQLは、簡単じゃない。慣れるまではとっつき憎いし、面倒だし、難しい。だから、少しづつ慣れていけばいいと思う」

Ebata: "Yes, SQL is not easy. Until you get used to it, it is difficult, troublesome, and hard. So I think you should get used to it little by little."

と言い直しました。

I reiterated.

-----

自分にできることを、他人に簡単に『簡単』と言ってはなりません。

Do not simply say 'easy' to others, even if you can do it yourself.

現在進行形で取り組んでいる人にとって、取り組んでいることが簡単なのは、そりゃ当たり前です。

Unsurprisingly, what we are working on is easy for us.

しかし、一度も経験していないことを始めることは、誰にとっても、莫大なコスト(時間と努力)と恐怖とプレッシャーがかかるものです。

However, starting something you have never experienced is an enormous cost (time and effort), fear, and pressure.

「他人にもできるはずだ」と決めつけて、他人に押しつけるようになる

-----

この件については、以前、私が「やらかした」ことをお話しました。

I have told you before what I "did" on this matter.

「江端、特許、パワハラ」で検索して貰えれば、このペ^ージや、その他のページでヒットします。

If you search "Ebata, patents, power harassment," you'll get hits on this page and others.

2023,江端さんの技術メモ

■通常のバスルートを作ったが、表示ノードが停留所のみとなり、シミュレータが不自然になる問題の解決法
   → 強制的にタグを付ける

mapconfig_for_cars_rail_cart_bus.xml

の変更も忘れないこと。

Keyword : osm, tag, node, ダイクストラ、

 

2023,江端さんの忘備録

昨日、市営図書館の書架で、故井上靖先生の「しろばんば」をみつけました。

Yesterday, I found "Shirobanba" by the late Yasushi Inoue on the shelves of the city library.

「しろばんば」「夏草冬濤」「北の海」は、著者のティーンエイジャ時代の自伝的小説です。

"Shirobanba," "Natsukaso Fuyutoto," and "Kita no Umi" are autobiographical novels about the author's teenage years

中学生時代、私は、土曜日午前で授業が終了すると、市場で自炊用の食材を買って、好きな料理を作って、それを食べながら、この本を読むことが、とても好きでした。

When I was in junior high school, I loved to read these books when classes ended on Saturday mornings, buy ingredients for my cooking at the market, cook my favorite dishes, and eat them while I read the book.

思い返せば、私は、主人公と自分を重ね合わせるように、ティーンの時代を生きてきたような気がします。

Thinking back, I feel like I lived my teen years as if I were superimposing on the main character.

『勉強っていいかも』『学寮っていいかも』『進学すれば、楽しいことがあるかも』と思わせてくれた本だったように思います。

I think this book made me think, "Studying may be good," "School dormitory may be good," and "If I go on to higher education, I may have fun.

-----

「しろばんば」を手にとって、パラパラを読み直してみたのですが、その「読みやすさ」にビックリしました。

I picked up "Shirobanba" and re-read the paraphrase and was surprised at its "readability.

フレーズの長さ、改行の入れかた、物語の登場人物の台詞の内容 ―― いわゆる「ラノベ」と言われているものの基本的技巧が満載で、驚きました。

The length of phrases, the way line breaks are inserted, and the content of the character's dialogue in the story -- I was surprised to find that the book is full of the basic techniques of what is called "Ranobe" (Light Novel).

また、故井上靖先生の本は、どれも「説教くさくない」というところも気にいっています。

I also like that the books by the late Yasushi Inoue are "non-preachy."

『起伏』や『濃淡』なくストーリーが展開されていて、どれも非常に読みやすいです。

The stories are developed without 'ups and downs' or 'shades of gray' and are easy to read.

-----

そういえば、先日、「マークスの山」について書きました。

By the way, I recently wrote about "Mark's Mountain".

「マークスの山」なら、「いいやつ」、「わるいやつ」、「わるいやつだけどいいやつ」というツリーの下に、「検察」「警察」「法曹」「マスコミ」「大学」「民間人」という分類を入れてもらえれば、随分助かります。

私は、北穂高ー槍ルートの5日間の縦走が1回、その後は、富士山登山の1回の経験しかありません。

I have only one experience, a 5-day traverse of the Kita-Hotaka-Yari route, and then one experience of climbing Mt.Fuji.

それでも、登山などを試みてみようと思ったのは、故井上靖先生の「北壁」の影響を受けたから、というような気がしています。

Even so, I feel that the reason I decided to attempt mountaineering was that I was influenced by the late Yasushi Inoue's "Hokuheki(North Cliff)."

読書は、単なる娯楽として楽しめば十分なのですが、ティーンの頃に読んだ本は、その後の人生にも影響を与えやすい ―― のかもしれません。

It is enough to enjoy reading as a mere pastime, but the books you read as a teen are likely to impact the rest of your life -- maybe.

-----

という訳で、ティーンエイジャの皆さん。

So, teenagers.

教師やご両親が『本を読め』とうるさく繰り返すのは、私と同じような体験をされてきたからかもしれません。

Perhaps teachers and parents have had the same experience I have had. Hence, they might loudly repeat, 'Read a book.'

うっとうしいとは思いますが、「大人とは『子どもが本を読んでいるのを見ているだけで安心する生き物」です。

I know it sounds annoying, but "adults are 'creatures that feel comfortable just watching a child read a book.'"

ですので、

Therefore,

―― 太宰や芥川の文庫本を、読みかけのようにして、リビングの床に落しておくだけ

"Drop a paperback book by Dazai or Akutagawa on the living room floor as if you were to continue to read it."

で、多分、皆さんのご両親は、ご機嫌になります ―― 多分。

If so, your parents will be in a good mood -- maybe.

『男性は、女性にとって、ゴキブリとハイエナを足して二で割ったようなものに見えていると思っておくくらいが丁度いい』