This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
import re | |
import os | |
def guess_column_types(file_path, delimiter=',', has_headers=True): | |
try: | |
# Read the CSV file using the specified delimiter and header settings | |
df = pd.read_csv(file_path, sep=delimiter, header=0 if has_headers else None) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
public function writeJsonFile($jsonFileNamePath, $jsonData) | |
{ | |
if (file_exists($jsonFileNamePath) ) { | |
preg_match('/^\[(.+)\]$/', $jsonData, $removeBracket); | |
$jsonFileHandle = fopen($jsonFileNamePath, 'c'); | |
// move back a byte | |
fseek($jsonFileHandle, -1, SEEK_END); | |
$pointerPosition = ftell($jsonFileHandle); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
I tried complied binary by https://www.johnvansickle.com/ffmpeg/ | |
./ffmpeg -y -i video-orignal.mp4 -i 1.mp3 -i 2.mp3 -filter_complex "[0:v] pad=width=iw:height=ih+200:x=0:y=100:color=#f2e6e6@0.99 [v_1];[1:a]atrim=0:11,adelay=6000|6000[1a];[2:a]atrim=0:15,adelay=130000|130000[2a];[1a][2a]amix=2[aout]" -map "[v_1]" -map "[aout]" video-final.mp4 | |
ffmpeg version 3.4-static http://johnvansickle.com/ffmpeg/ Copyright (c) 2000-2017 the FFmpeg developers | |
built with gcc 6.4.0 (Debian 6.4.0-7) 20170920 | |
configuration: --enable-gpl --enable-version3 --enable-static --disable-debug --disable-ffplay --disable-indev=sndio --disable-outdev=sndio --cc=gcc-6 --enable-fontconfig --enable-frei0r --enable-gnutls --enable-gray --enable-libfribidi --enable-libass --enable-libvmaf --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librubberband --enable-librtmp --enable-libsoxr --enable-libspeex --enable-libvorbis --enable-libopus --enable-libtheora |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
packages: | |
yum: | |
openssl-devel: [] | |
python27-setuptools: [] | |
container_commands: | |
01-supervise: | |
command: "chmod +x .ebextensions/supervise.sh" | |
02-supervise: | |
command: ".ebextensions/supervise.sh" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace App\Test\JSONListener; | |
use \JsonStreamingParser\Listener; | |
class JSON2CSV implements Listener | |
{ | |
private $_current_row; | |
private $_outfile; | |
private $_key; |