1/27/2020

python year month day expression using datetime

Without any separator
import datetime
datetime.datetime.now().strftime("%Y%m%d%H%M%S")
Using - as separator
import datetime
datetime.datetime.now().strftime("%Y-%m-%d-%H-%M-%S")
Using _ as separator
import datetime
datetime.datetime.now().strftime("%Y_%m_%d_%H_%M_%S")

1/03/2020

OpenCV Docker error "ImportError: libSM.so.6: cannot open shared object file: No such file or directory"

Try this command

apt-get update
apt-get install -y libsm6 libxext6 libxrender-dev
pip install opencv-python