2024,江端さんの忘備録

江端家の家訓

The Ebata family motto

1. 人の意見は、聞いてもいいが、聞かなくてもいい。

1. we may or may not listen to people's views.

啓蒙書は、もう読まない

2. 水場より高い場所に居所を構える

2. we take up our abode above the water

ただ、他の場所と比較して、「相当に悲惨な苦痛」と「耐え難い苦難」と「非人道的な死」の可能性が、相当に高い場所に立っているんだ ――

3. マラソン大会と運動会は、仮病で休んでもいい

3. We are allowed to miss marathons and sports days on a temporary sick day

正直に言いますけどね、本当に『みじめ』でしたよ。

実際に、私は、娘の保護者として、学校に仮病の連絡を入れていました。

In fact, as a parent of a daughter, I had informed the school of her temporary sickness.

-----

というような話を家族にしたら、『家訓がショボすぎる』と言われました。

When I told my family about it, they said, 'The family motto is too shabby.'

2024,江端さんの忘備録

外出が面倒くさいので、嫁さんが実家に帰省している間は、基本的に自炊しています。

I cook for myself while my wife is back at her parent's house because going out is too much of a hassle.

で、今日、冷蔵庫の中を見たら、凍っている納豆2パックと、挽肉100グラムが残っていました。

So today, I looked in the fridge and found two packets of frozen natto and 100 grams of minced meat left.

-----

話はちょっと横道にそれますが、私が米国コロラド州のフォートコリンズという街に赴任していた時、日本人コミュニティは、ある種のライフライン(生命線)でした。

Off-topic, the Japanese community was a lifeline when I was in Fort Collins, Colorado, USA.

で、日本人コミュニティから提供される情報の中で、もっとも重要な情報の一つが、「日本食」です。

One of the most essential pieces of information the Japanese community provides is Japanese food.

フォートコリンズは、いわゆる学園都市ともいえる清潔で住んでいる人の知的レベルの高い街だったと思いますが ―― 州都デンバーまで100kmありました。

Fort Collins was a clean school town, and the intellectual level of the people who lived there was high. However, it was 100 km far from the state capital, Denver.

もちろん、フォートコリンズでも、日本食は手に入りましたが、それでも、美味しい米を食べたいと思えば、デンバーまで往復200kmかけて買い出しに行かなければなりませんでした。

Of course, Japanese food was available in Fort Collins, but even then, if you wanted good rice, you had to travel 200 km round trip to Denver to buy it.

-----

しかし、本当に稀ですが、フォートコリンズにあって奇跡的に手に入るものがありました。

However, one was miraculously available in Fort Collins, although it was scarce.

それが「冷凍納豆」と「冷凍刺身の切り身」です。

These are 'frozen natto' and 'frozen sashimi fillets.'

このニュースを手に入れると、私は出社を遅らせて、店舗に向かい、その商品を手に入れました。

もちろん、味は、日本では、多分陳列すらされないであろう、もっとも品質の悪い納豆、または、廃棄されそうな刺身ではありましたが、それでも、家族で喜びあったものです。

Of course, the taste was of the poorest quality natto (fermented soybeans) without being displayed in Japan or sashimi, discarding, but still, the family was delighted.

これが米国のリアルです。

The above is the reality in the USA.

私が、ずっと、ニューヨークやフロリダ、サンフランシスコ、特に、サンノゼを『あそこは米国でない。日本だ』と、僻み続けてきたのは、こういう事情です。

I've always been backbiting New York, Florida, San Francisco, and especially San Jose, saying, 'That's not the United States, that's not the United States. It's Japan'.

今でも、冷凍庫の中に放りこんである納豆パックを見ると、その記憶が蘇えります。

Even now, when I see a pack of natto thrown in the freezer, the memory returns to me.

閑話休題

Now, let's return to the main subject

-----

凍っている納豆2パックと、挽肉100グラムで、何ができるか探そうと思ったのですが、面倒なので、ChatGPTにレシピを考えて貰うことにしました。

I was going to find out what I could do with two packets of frozen natto and 100 grams of minced meat, but it was too much trouble, so I decided to ask ChatGPT to devise a recipe.

質問:納豆と挽肉をつかった丼の作り方を教えて下さい。

Q: How do you make a rice bowl with natto and minced meat?

回答:

ANSWER:.

納豆と挽肉を使った丼は、簡単に作れて栄養満点の一品です。以下にその作り方を紹介します。

A rice bowl with natto and minced meat is easy to make and nutritious. Here are some instructions on how to make it.

納豆と挽肉の丼のレシピ

Recipe for natto and minced meat rice bowl

材料(2人分)

  • ご飯:2杯分
  • 納豆:2パック
  • 挽肉(豚肉または鶏肉):150g
  • 玉ねぎ:1/2個
    (中略)

Ingredients (for two persons)
Rice: 2 cups
Natto (fermented soybeans): 2 packets
Minced meat (pork or chicken): 150 g
Onion: 1/2 onion
(Omitted)

ちょっとアレンジしましたが、結構良い味でした。

I arranged it a bit, but it tasted quite good.

『これからは、料理のパラダイムが変わるなぁ』と実感しました。

'I realized that the cooking paradigm will change from now on.

-----

これからの料理は、料理をするために食材を購入するのではなく、

Cooking in the future is not about buying ingredients to cook with,

―― 残っている材料を組み合わせて、逆算して作る

"Combine leftover ingredients and work backward."

というものになりそうです。

is come to be usual.

これからは、名前のない料理が、私たちの主食になっていくかもしれません。

In the future, dishes with no name may become our staple food.

これは、SDGs的にも良さそうです。

It looks good from an SDG perspective.

-----

って、嫁さんに言ったら、

I said to my wife, and she said 

『それ、普通』

"That's already normal."

と言われました。

通常の検索エンジニンで、普段から同じことをやっているそうです。

They usually do the same with normal search engines.

-----

今度、ChatGPTに、『コーラとカレールーを使った料理』を考えてもらうことにします。

Next time, I will ask ChatGPT to create a 'dish with cola and curry roux.'

「コーラ」で「カレー」を作る

2024,江端さんの忘備録

ご存知の通り、私、ねちっこくてしつこい性格をしています。

As you know, I have a vindictive and persistent personality.

ですから、エンジニアとして『2位じゃダメなんでしょうか』を、まだ許していません。

So, as an engineer, I have not yet allowed myself to say, 'Is second place not good enough?

私が調べた限り、自己批判も撤回もしていないようです ―― ということは、『技術分野における"2位"』というフレーズに、どれほどのエンジニアに対する侮辱が入っているかを、分かっていないのだろうと、理解しております。

As far as I can tell, she has neither criticized herself nor retracted - so I understand that she does not realize how much of an insult to engineers is contained in the phrase 'second place' in engineering.

もちろん、これ以上の暴言や妄言を吐いていた人(政治家)は山ほどいますが、私が、この発言を『絶対に許せない』と思えるのは、私がたまたまエンジニアだったからだ、と思います。

Of course, plenty of people (politicians) have been even more outspoken and delusional than this. Still, I think the only reason I believe this statement is 'unforgivable' is because I am an engineer.

この発言に対する私の拘泥(こだわり)は、私自身でも異常と思えるほどですが ―― 申し訳ないですが、運が悪かったと思って、諦めて下さい。

My obsession with this statement seems extraordinary even to me. However, I'm sorry, but please consider it bad luck and give up.

自己批判、または、撤回して貰えれば、私も忘れることにしますが、そうでない限り、私はあなたの支持だけはできません、終生。

If she self-criticizes or recants the opinion, I will forget about it. However, I cannot support her in my life unless she does.

(8) 『信仰でコロナ感染を防ぐ』とか唄っていたアホな教祖の党の候補者は、論外

上記の(4)をご参照下さい。

See (4) above

事業仕分けに関する一考察

 

2024,江端さんの忘備録

「新幹線は、騒音公害の代名詞だった」と聞いて信じる人は、どれくらいいるでしょか。

How many people believe it when they hear that "the Shinkansen train was synonymous with noise pollution?"

昔の新幹線は、本当に凄い騒音を出しながら運行していたのです。

In the past, bullet trains used to operate with really great noise.

「昼夜かまわず、低能ライダーが騒音撒き散らして走り回っている」という感じでした。

'It was like, "day and night, there's a bunch of lowlife riders riding around, spreading noise all over the place."'

当然、地域住民は訴訟をおこします。「名古屋新幹線訴訟」です。

Naturally, residents file a lawsuit. The Nagoya Shinkansen Lawsuit.

当時の私の家は、新幹線の路線沿線にありましたので、よく覚えています。

I remember it well because my house was along the Shinkansen line.

-----

当時は、水俣病、新潟水俣病、イタイイタイ病、四日市ぜんそくなど、重大な公害の横行を社会が認容していました。

At the time, society accepted the rampant occurrence of severe pollution, including Minamata disease, Niigata Minamata disease, Itai-itai disease, and Yokkaichi asthma.

行政府は勿論、司法も、立法も「経済成長 >> 市民生活」という ―― そういう時代だったのです。

It was a time when the executive, judiciary, and legislature were "economic growth >> civic life" - that's how it was.

ですので、映画「三丁目の夕日」などを含め、私は、昭和という時代を

That's why, including the film Sunset on Third Street, I think of the Showa period as 

『どうやったら、あんなクソッタレな時代に、郷愁を感じることができるのか』

'how can you feel nostalgia for such a shitty time?

と、そんな風に思っている訳です。

私が見てきた限り、「今日は昨日より良いし、多分、明日は今日より良い」は、外れていないと思います。

As far as I can tell, "Today is better than yesterday, and maybe tomorrow will be better than today" is not out of line.

はっきり言えば、「過去は常に悪い」です。

To put it bluntly, 'the past is always bad.'

-----

長女が「一人暮らしを始めたい」と言った時に、私は、真っ先に賛成し、さっそくそのアパートを見にいったのですが、その場所に驚きました。

When my eldest daughter said she wanted to start living independently, I was the first to agree and immediately went to see the apartment, which surprised me with its location.

新幹線の高架まで、わずか15メートル。

Only 15 metres to the elevated Shinkansen line.

『ここ、大丈夫か』と思いました。

I thought, 'Is this place OK?'

しかし、部屋の中では、新幹線が通っていることは認識できるのですが、「騒音」という感じではありませんでした。普通の私鉄沿線より、ずっと静かなんじゃないかな、と、思ったくらいです。

However, in the room, although I could recognise the Shinkansen trains passing by, it did not feel like 'noise'. It was much quieter than a normal private railway line, or so I thought.

―― やればできるもんだ

"They can do it, can't they ?"

と感心しました。

I was impressed.

-----

「名古屋新幹線訴訟」の後、裁判所は新幹線に対して被害地区における新幹線の減速する旨の命令を出し、その後、新幹線騒音に関する法律の制定や、各種の革新的な騒音対策技術の開発が行われ続けて、今に至っています。

After the Nagoya Shinkansen Lawsuit, the court ordered the Shinkansen to slow down in the affected area. Then, Shinkansen noise legislation was enacted, and various innovative noise control technologies were developed.

これは、新幹線騒音の被害者が、諦めることなく、声を上げ続けたからこそ、実現されたのです。

The above was only possible because the victims of bullet train noise never gave up and continued to speak out.

-----

よく使われるフレーズに、『あいつら、ソリューション(解決策)も出さずに、文句を言い、叫び続けているだけ』という、批判の仕方があります。

A common phrase used in criticism is 'they just keep complaining and shouting without offering solutions.'

いわゆる、

So-called, it is

―― 反対するなら対案を出せ

"If you disagree, give me a counter-proposal."

というやつです。

うん、私は、そう言いたくなる気持ち、よく理解できます。

Yes, I can understand why you would want to say that.

私が睡眠時間を削って案出した案を、簡単に否定する顧客、幹部、上司、同僚に対して、私は、なんどこのフレーズを言いかけたことか。

How often have I almost uttered the phrase to customers, executives, bosses, and colleagues who just dismissed the ideas I had squeezed without sleeping?

でも、これは、絶対に言ってはならない禁句なのです。クライアントのご意見は(そのクライアントが絶望的なバカでない限り)絶対です。

But this is forbidden. The phrase is taboo. The client's opinion (unless that client is a hopeless idiot) is absolute.

ソリューション(解決策)も出さずに、文句を言い、叫び続けている"だけ"の行動が、立法府(国会)に法律を作らせ、企業(当時の国鉄)に技術革新を促せることもあるのです。

Sometimes, it is 'just' complaining and shouting, without offering solutions, that forces the legislature (parliament) to make laws and companies (the Japanese National Railways at the time) to innovate.

もちろん、被害者は「元の生活に戻せ」と主張する権利があります。

Of course, victims have the right to insist that their lives be 'restored.'

それに加えて、こういう、"だけ"の行為が、状況を改善する力になりえるのです。

In addition to this, this kind of "just" action can be a force for improving the situation.

"対案がなくても反対していいんですよ" ―― と、提案者であることの多い私は、ひきつった笑顔で、そう言わざるをえません。

"You can oppose it without a counter-proposal," - I have to say, with a drawn-out smile, as I am often the proponent.

-----

繰り返しますが、『騒音被害のない新幹線など、"夢物語"』と思われた時代は、確かにあったのです。

Again, there was a time when Shinkansen trains without noise damage was a 'pipe dream.'

2024,江端さんの忘備録

以前、私の後輩がいました。そしてその後輩には部下がいました。

There used to be a junior colleague of mine. And my junior had a subordinate.

彼は、自分の仕事(特許庁からの拒絶理由対応)を、部下にやって貰おうとしていたことがあったのですが、業務命令の理由をロジカルに説明できず、『年長者マウント』で、その業務を新人にやらせようとしていました。

He once tried to get his subordinate to do his job (responding to reasons for refusal from the patent office). Still, he could not logically explain the reasons for the work order and was 'elder mounted' and tried to get a newcomer to do that job.

私は、このやりとりを横から見ていたのですが、特許に関することだったので、口出しをしてしまいました。

I watched the exchange from the side and interjected because it was about patents.

―― 自分で生み出していないモノ(特許明細書)を、その発明に関与していない人に頼むことは、筋が通っていないし、無理だと思う

"I don't think it makes sense or is impossible to ask someone who has not been involved in the invention to do something (patent specification) that the persons did not create by themselves."

と。

まあ、要するに、私は、公然と、後輩のメンツを潰した訳ですよ。

In short, I have openly and publicly made him lose face.

-----

私も同じ状況になったことはあります。

I have been in the same situation.

この時に、私がこの困難を乗り越える為にやったことは一つです。

One thing I did at this time to overcome this difficulty was shouting 

『お願いします! どうか、私を助けて下さい!』

'Please! Please help me!"

と、真剣に心の底から土下座してお願いをする ―― この一択です。

Seriously, I will get down on my knees from the bottom of my heart and make a request—this is the only option.


-----

私、後輩やら先輩やらの区別の意識は、あまり持っていません。

I don't have a sense of distinction between juniors and seniors.

上司や幹部には『忖度』はしますが、それは単なる『手段』です。

I consider the boss's feelings or wishes, but it is a 'means.'

今だって、現役大学生の皆さんに、頭を垂れて色々と助けて貰っています。

Even now, I bow my head to university students to request something.

そもそも、私の研究指導をして頂いている大学の先生は、全部年下です(当たり前ですが)。

To begin with, all of my research supervisors at the university are younger than me (of course).

誰であろうとも助けて頂いている方に対して、最大の礼を尽すのは、人間として当たり前のことです。

It is natural for human beings to extend the most significant possible courtesy to those helping me, whoever they may be.

-----

私は、このマインドのお陰で、下らないマウントを取る必要なく、業務を行なっています。

Thanks to this mindset, I can do my business without the need to mount a trivial

この私のマインドは、いつごろどこで生成されたのかなぁと思い出してみると、『嫁さんへのプロポーズの時からかなぁ』と思います。

When I remember when and where I set this mindset, I think, 'Maybe since I proposed to my wife.'

「一緒になって貰うために、地に這いつくばい、泥をすすり、自尊心を投げうって、彼女の足を舐めるような屈辱を経て、結婚を承諾して貰った」

'To get her to marry me, I had to crawl on the ground, slurp mud, throw away my self-respect, and go through the humiliation of licking her feet.'

江端さんのひとりごと 「メールのやり取り(その8)」

私のこのマインドは、この時に完成した、と思うのです。

I think I have completed the mindset at this time.

2024,江端さんの忘備録

『“ひきこもり”約146万人の衝撃』という記事を読みました。

I read an article titled "The impact of 1,460,000 'hikikomori(shut-in)'".

引きこもり、引きこもり・・・ ―― 昔、何かで調べたような気がします。

Hikikomori, Hikikomori...  I think I looked something up a long time ago.

あ、これだ。

I got it.

私、このコラムで「引きこもりの当事者のマインド」ではなく、「引きこもりを憎悪する人間のマインド」についての解析を行っています。

In this column, I am not analyzing the mindset of the shut-in party but the mindset of people who hate shut-ins.

このコラムを執筆してきた時の私は、あくまで、「ひきこもり」の"当事者"という意識はなく、あくまで、"観察者"という立ち位置でした。

When I wrote this column, I was not conscious of being a "shut-in" but rather an "observer."

私、自分が「抑うつ」の症状が出ることが分かってから、この「ひきこもり」の当事者の心理が、本当にうっすらとですが、分かってきたような気がします。

 since I found out that I have symptoms of depression, I think I have started to understand the psychology of this 'shut-in' party, although it is very faint.

―― 人間が怖い

"Fear of people."

「抑うつ」が生じている時に、こういう気持ちが湧き上がってくるのです。

I get these feelings when I am experiencing 'depression.'

ただ、私が「ひきこもりの人の気持ちを完全に理解しているか」と問われると、自信がありません。

However, I am not confident that I fully understand the feelings of shut-in people.

私、多くの人前でプレゼンするの好きですし、会話もするし、話題も色々出せる方だと思います。

I like to present in front of a lot of people. I want to have conversations, and I think I'm a person who can give a lot of topics.

それでも、個人との会話に恐怖を感じることはあります。

Nevertheless, there is still a fear of talking to individuals.

ですから最近は、日本人と会話するより、海外の留学生との会話の方が、なんとなく「気持ちがラク」です。

So these days, it is somewhat 'easier' to talk with foreign students than with Japanese people.

"お互い分かりあえなくても、仕方がないよね"という意識が、なんとなく私をラクな気持ちにさせているのかもしれません。

It seems to me that the awareness that "even if we don't understand each other, it cannot be helped" somehow makes me feel more at ease.

ともあれ、確かに「人が怖い」と感じることは、確かにあるのです。

Anyway, it is undoubtedly true that I am sometimes afraid of people.

これは、「抑うつ」という病気を通じて、私が獲得した感情の一つであると思っています。

I believe this is one of the emotions I have acquired through the illness of 'depression.'

別に欲しくもない感情ではありましたが。

It was a feeling I didn't want.

-----

私は、このコラムの中で、(1)「ひきこもりの人は、3つの仮想敵に攻撃され続けて苦しんでいる」という論と、

In this column, I argue that (1) 'the shut-in person is suffering from a constant attack by three virtual enemies.'

(2)「明日は我が身である」という論を展開しました。

I further argued that (2) "tomorrow is my day."

本日の結論ですが ―― 本当に「明日は我が身」ですよ。

Today's conclusion -- is "Tomorrow is my day."

 

―― 「また食事を摂らなけばならない」と思うだけで、明日が来るのが怖い

2024,江端さんの忘備録

会社の部内では、「自分の心掛けている安全」について投稿する、という運用がされています。

The operation within the company's department is to post about ‘safety that you are mindful of.’

一日一投稿で、毎日行なわれていますので、一定の期間で順番が回ってきます。

We post one post per day, so my turn comes in some months.

で、昨日私は、「飲酒」について投稿しました。

So yesterday I posted about ‘drinking’.

まあ、私の飲酒についての経歴はこちらをご覧下さい。

Well, you can read more about my drinking background here.

-----

本日の投稿前に、ネットで色々調べていたのですが、

I had done a lot of research on the internet before today's post,

『断酒をしてから、自分の生活に余裕がなくなったように感じる、あるいは、他人からそのように見られるようになった』

‘Since my sobriety, I feel like I have less room in my life or that others see me that way.’

という記述を見て、ドキっとしました。

This description shocked me.

―― 思いっきり、身に覚えがある

"I do remember that."

断酒後、私は、酔っぱらうことがなくなり、飲み会の後でも余裕で仕事ができるようになりました。

After sobriety, I am no longer intoxicated and can work in plenty of time after a drink.

私、このことを自慢気に言ってきたような気がします。

I think I have been bragging about this.

しかし、今、これは『自分を追いつめていること』だったように思えます。

But now it seems that this was ‘pushing myself.’

今の世の中、何事にも、きちっと考えて、真面目にやっていたら、自分を壊します。

In today's world, if you think correctly and take everything seriously, you will destroy yourself.

で、私、こっちの「自分を壊す」方も、がっつり経験者です。

And I've had a lot of experience with the ‘destroy myself’ one.

-----

これ、真面目な話なのですが、今の私は、

I am seriously drifting into the following bewilderment.

『一体、私は何をどうすればいいんだ?』

‘What on earth am I supposed to do?’

という、困惑の中に漂っています。

 

未分類

Social Impact Simulation Including Social Capital, Based on Current Status of Multi-Agent Simulation

https://www.iaiai.org/journals/index.php/IJSKM/article/view/834

  • Tomoichi EbataHitachi, Ltd.
  • Ryo AriyoshiNagoya University
  • Shinji TanakaYokohama National University
Keywords: Multi-Agent Simulation (MAS), Social Capital (SC), Social Impact Bond (SIB), Social Impact Simulation (SIS), Subjective Well-Being (SWB)

2024,江端さんの技術メモ

C言語を使えて、GStreamerが使えて、GO言語を使えて、CGOが使える環境を作っています。

(1)Windowsの方のmsys2とGStreamerのパッケージを削除
Windowsの方のC言語、GStreamerはコンフリクトするので削除しますが、GO言語は、別のタスク(大学の方のシミュレータ)があるので、削除できませんでした。
という訳で、MSYS2の環境を、Windowsの方と切り離して運用するという覚悟ができました。

(2)C:の容量が小さいので、G:\の方にパッケージを分離していたのですが、これをやると、全く動かなくなるので、C:\msys2の配下に勝手に作成される、/c/msys64/home/tomoi/の直下でプログラムの作成をすることにしました。

これ、/usr/local/binの配下に/home/ebataを作るような気持ち悪さがあるのですが、今回は稼動が最優先です。

MSYS2のインストール

  1. MSYS2公式サイトからインストーラをダウンロードします。
  2. インストーラを実行し、画面の指示に従ってMSYS2をインストールします。

2. MSYS2の初期設定

  1. MSYS2ターミナルを起動: MSYS2 MSYSショートカットを使用してMSYS2ターミナルを起動します。
  2. パッケージデータベースと基本パッケージの更新: 以下のコマンドを順番に実行して、パッケージデータベースと基本パッケージを更新します。

    sh

    pacman -Syu

    初回のアップデートが完了したら、ターミナルを一度閉じて再起動します。

  3. 再度更新を実行: ターミナルを再起動後、再度以下のコマンドを実行します。

    sh

    pacman -Syu

3. MinGW-w64のインストール

  1. MinGW-w64ツールチェインのインストール: MSYS2 MinGW 64-bitショートカットを使用してMSYS2ターミナルを起動し、以下のコマンドを実行します。

    sh

    pacman -S mingw-w64-x86_64-toolchain

    これにより、GCC、G++、およびその他の開発ツールがインストールされます。

4. 環境変数の設定

MinGW-w64のバイナリにアクセスするために、環境変数PATHを設定します。

  1. ~/.bashrcファイルの編集: MSYS2ターミナルで~/.bashrcファイルを開きます。

    sh

    nano ~/.bashrc
  2. PATHの設定: 以下の行を追加して保存します。

    sh

    export PATH="/mingw64/bin:$PATH"
  3. 設定の反映: 設定を反映させるために、ターミナルを再起動するか、以下のコマンドを実行します。

    sh

    source ~/.bashrc

5. GStreamerのインストール

  1. GStreamerのパッケージのインストール: MSYS2 MinGW 64-bitショートカットを使用してMSYS2ターミナルを起動し、以下のコマンドを実行します。

    sh

    pacman -S mingw-w64-x86_64-gstreamer mingw-w64-x86_64-gst-plugins-base mingw-w64-x86_64-gst-plugins-good mingw-w64-x86_64-gst-plugins-bad mingw-w64-x86_64-gst-plugins-ugly

    pacman -S mingw-w64-x86_64-gstreamer mingw-w64-x86_64-gst-plugins-base mingw-w64-x86_64-gst-plugins-good mingw-w64-x86_64-gst-plugins-bad mingw-w64-x86_64-gst-libav

6. 確認とテスト

  1. GCCの動作確認: GCCが正しくインストールされているか確認します。

    sh

    gcc --version
  2. 簡単なCプログラムの作成とコンパイル: 簡単なCプログラムを作成してコンパイルします。

    sh

    nano test.c

    以下の内容を入力します。

    c

    #include <stdio.h>

    int main() {
    printf("Hello, World!\n");
    return 0;
    }

    ファイルを保存してNanoエディタを閉じた後、コンパイルします。

    sh

    gcc test.c -o test.exe

    コンパイルが成功したら、実行します。

    sh

    ./test.exe
  3. GStreamerの動作確認: GStreamerが正しくインストールされているか確認します。

    sh

    gst-launch-1.0 --version

    簡単なGStreamerパイプラインを実行して動作確認します。

    sh

    gst-launch-1.0 videotestsrc ! autovideosink

とうぜん 、ここまですんなりできた訳ではありませんが、取り敢えず私が思い出せる程度の情報を載せてあります。

-----

https://github.com/go-gst/go-gst

から、/home/tomoi/go/srcで、 git clone https://github.com/go-gst/go-gst をして、/home/tomoi/go/src/go-gst を作って、

に張ってあったプログラムを、main.goでセーブしたのち、

go run main.go videotestsrc ! glimagesink

で、

と、

が、表われることを確認。

なにがどうなっているのかは、サッパリ分からないが、とりあえず、GoからGstreamerが動いたことは確認できた。

以上

なんか、サラっと書くと自分でも腹たつなぁ。10時間以上はかかったんだけどなぁ

2024,江端さんの忘備録

私は、複数の言語(プログラミング言語のことです)を使うことができます。

I can use more than one language (i.e., programming languages).

とくに、C言語とGO言語については、かなり使い込んでいまして ―― 現在も、私は、会社の中で『呪文言語を扱う魔術師』という立ち位置で、使い倒されています。

In particular, I have used the C and GO languages to a great extent - even now, I am used to the position of ‘spell-casting language wizard’ in the company.

「パソコンを使っただけで不当に尊敬された時代」に、強制的にタイムリープさせられたような感じになりました。

C言語とGO言語は、設計思想が似ていて、GO言語はC言語の進化形とも言われることがあります(私は、違うと思っているのですが)。

The C and GO languages have a similar design philosophy, and the GO language is sometimes said to be an evolution of the C language (although I think it is not).

で、当然、この2つを融合させて使おうという発想が出てくるわけです。

So, naturally, the idea is to use a fusion of the two.

これが、"cgo" ―― GoからCの関数/型にアクセスするために用いるパッケージであり、簡単に言えば、『Cで書かれたライブラリを、Goでも再利用できる』ようにするものです。

This is ‘cgo’ - a package used to access C functions/types from Go, which, simply put, allows ‘libraries written in C to be reused in Go’.

-----

私、何年か前に、このcgoを試みて、失敗しております。

Some years ago, I tried and failed to do this 'cgo'.

まあ、趣味でやっていたものなので、失敗しても気にしていませんでした。

It was my hobby, and I didn't mind if it failed.

-----

ところが、これが、"業務"となると、全く話が違ってきます。

However, when it comes to ‘business,’ the story is entirely different.

『動かさなければ、何もしなかったことになる』 ―― これが、ソフトウェア開発の怖いところです。

‘If you don't move it, you haven't done anything’ - this is the scary part of software development.

そもそも、参考文献が少ないし、下手すると『全くない』てなこともあります。

There are few references, and in some cases, ‘none at all.’

仕事としてプログラミングをやる人にとって、出版されている本は、役に立たないことが多いです。

For those who do programming as a job, published books are often not helpful.

本の内容が『そんなことは知っとるわ!』となってしまうことは、仕方がないことです。

When reading the book, ‘I already knew it’ is inevitable.

-----

ただ ―― 動かないプログラム、動かないシステムというのは、本当に怖いです。

However,  a program that doesn't work, a system that doesn't work, is horrifying.

一週間、一日18時間、パソコンと格闘していたとしても、プログラムが動かなければ、『あんた、この一週間、何やってたの?』と言わるかもしれない、という恐怖が常に付きまといます。

There is always the fear that if you work on a computer 18 hours a day for a week and the program doesn't work, you might be asked, ‘What have you been doing all week?’

特許明細書や報告書は、内容はどうあれ、書けば増えますし、いつかは終わります。もちろん、これらの業務がラクであると言う気はありませんが。

Patent specifications and reports, whatever their content, will increase as they are written and will be finished at some point. Of course, I don't mean to suggest that these tasks are easy.

しかし、成果が"0"か"1"でしか評価できないプログラム ―― しかも、それが、自分だけの努力では、なんともならないもの(例:ハードウェアやミドルウェアとの相性)である場合は、もうどうしようもありません。

However, if the results of a program can only be evaluated on a scale of ‘0’ or ‘1’ - and this cannot be managed by your efforts alone (e.g., compatibility with hardware or middleware), there is nothing more you can do.

-----

ChatGPTは、かなりがんばってくれています。

ChatGPT has done a lot of work.

私が、

When I said, 

『そのやり方、今日、3回目の同じ説明だけど』

‘That's the third time today I've had to explain the same thing that way.’

と嫌味を言うと、きちんと謝罪して見せた後で、4回目の説明を始めてしまいます。

When I am sarcastic in this way, ChatGPT apologizes and adequately starts explaining for the fourth time.

仕方ないですよね。

It can't be helped.

ChatGPTだって『なんでもは知らないわよ。知っていることだけ』と言いたいことでしょう。

Even ChatGPT would have said, ‘I don't know everything. Only what I know.

ChatGPTが知らないことは、それはもう膨大にあります。

There is a considerable amount that ChatGPT does not know.

そして、世の中に新しいものが登場するたび、ChatGPTも、ゼロから勉強しなければならないです。

And every time something new appears, ChatGPT must also learn from scratch.

-----

ともあれ、先程、人生最初のcgoのプログラムが動いて、今、私は安堵の溜息をついています。

Anyway, I just got the first 'cgo' program working, and I sigh with relief.

不安の溜息と安堵の溜息 ―― ソフトウェアエンジニアは、いつだって溜息をついています。

Sighs of anxiety and sighs of relief -- Software engineers are always sighing.

「羽川翼の決めセリフ、『何でもは知らないわよ。知っていることだけ』の初出は?」