>>tosho.py
import pandas as pd
a=pd.read_excel("https://www.jpx.co.jp/markets/statistics-equities/misc/tvdivq0000001vg2-att/data_j.xls")
print(",".join([str(s) for s in a["コード"][a["市場・商品区分"]!="PRO Market"]]))
中東戦争の経緯について教えて
中東戦争(The Middle East War)は、20th 世紀にわたり複数の軍事的な conflicting claims to territory, and political and ideological differences have led to a number of significant conflicts in the Middle East. Here are some of the key events and factors that have contributed to the outbreak of war in the region:
1. The fall of the Ottoman Empire: The Ottoman Empire, which once ruled much of the Middle East, began to decline in the late 19th century. During and after World War I, the empire collapsed, leading to the creation of new states in the region, including Iraq, Syria, Lebanon, Jordan, and Palestine. These new states were created through a series of agreements between the Allied powers, including Britain and France, and were often drawn along arbitrary borders that did not take into account the region's complex ethnic and religious diversity.
2. The establishment of Israel: The establishment of the state of Israel in 1948 was a major flashpoint in the Middle East. Many Arab states rejected the creation of Israel and launched a series of wars to try to destroy it. Israel emerged victorious in these wars, leading to the displacement of hundreds of thousands of Palestinians and fueling resentment and anger towards Israel and the West.
3. The Iranian Revolution: The 1979 Iranian Revolution, which overthrew the US-backed Shah and established an Islamic republic, was another significant event in the region. The revolution had a profound impact on the Middle East, inspiring other Islamic movements and leading to a rise in anti-Western sentiment.
4. The Gulf War: The Gulf War of 1990-91, which was triggered by Iraq's invasion of Kuwait, was another major conflict in the region. The war saw a coalition of Western and Arab states led by the United States intervene to expel Iraqi forces from Kuwait. The war had significant consequences for the region, including the destabilization of Iraq and the rise of Islamist groups.
5. The US invasion of Iraq: The US-led invasion of Iraq in 2003, which was justified on the grounds of removing weapons of mass destruction, has been widely criticized as a major factor in the destabilization of the region. The invasion led to a power vacuum that was filled by various militia groups and terrorist organizations, including ISIS.
These are just a few of the key events and factors that have contributed to the outbreak of war in the Middle East. The region's complex history, ethnic and religious diversity, and strategic importance have made it a flashpoint for conflict for many years, and it remains a volatile and unstable region today.
3coins で売ってたマルチローラーボールってマッサージ用のボールがとてもいい。5 cm くらいのプラスティック製のボールに持ち柄がついていてスムーズに転がり、足の裏とかコロコロするのにとてもいい。同じ文末にしても仕方がないと思うくらいには気に入っている。google:マルチローラーボール 3coins
2/29-3/3 に SOURCENEXT でソフト配布やるみたいなので3/1に Rosetta Stone をもらおうか迷い中。他のは使わないだろうから遠慮しておこう。
下に書いたコード以外にも silencedetect で stderr に出てきたのを正規表現で抜き出して、無音の最初と最後をリストにして zip 関数使って組み合わせて数数えてとかやっているのですが、大体下のに入っていたので割愛。
jupyter notebook 上で
import subprocess
import re
import os
from IPython.display import clear_output
import pickle
dirs=os.path.join(os.path.expanduser("~"),"Desktop","1900_3_all")
cwd=os.getcwd()
os.chdir(dirs)
s={}
dirlist=sorted([f for f in os.listdir(dirs) if f.endswith(".mp3")])
# cc=76for n,f inenumerate(dirlist):
# if n<cc:# continue# if n==cc:# s=pickle.load(open("./test.pkl","rb"))file=os.path.join(dirs,f)
a=subprocess.run(f"ffmpeg -i {file} -af silencedetect=n=0.001:d=1:m=0 -vn -f null -", capture_output=True, text=True,encoding="utf-8")
file_end=[float(f) for f in re.findall('silence_start: (\d+.\d+)\n',a.stderr)]
file_start=[0]+[float(f) for f in re.findall('silence_end: (\d+.\d+)',a.stderr)]
a,b,c=os.path.splitext(f)[0].rsplit("_",2)
idealfiles = 1+int(c)-int(b)
file_time=[(s,t) for s,t inzip(file_start,file_end)]
if idealfiles==len(file_time):
continue
checked=0for i,t inenumerate(file_time):
print(f"{n} {i+1}/{checked}/{1+int(c)-int(b)}/{len(file_time)},{n}/{len(dirlist)}")
if checked+(1+int(c)-int(b))==len(file_time):
continue
subprocess.run(f"ffplay -i {f} -ss {t[0]} -t {t[1]-t[0]+0.5}")
aa=input("OKならEnter、問題ありなら文字入力後Enter")
clear_output()
if aa:
s.setdefault(n,[]).append(i)
checked+=1
pickle.dump(s,open("./test.pkl","wb"))
os.chdir(cwd)
s