Python Forum
batch python in android
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
batch python in android
#1
hi, sorry for my bad english,

i will show you the code first

:parse
IF "%~1"=="" GOTO endparse
call :handle_one_file %1
SHIFT
GOTO parse
:endparse

:handle_one_file
cls
TITLE %1 %date%-%time% 
if exist "%~dpn1%~x1".txt goto skip_delete
ECHO %1 %date%-%time% >> "%~dpn1%~x1".txt
md D:\"%~p1"
"C:\PySceneDetect-0.4-win64-portable\scenedetect.exe" --input "%~dpnx1" -df 16 --output "D:%~pn1-%~x1" >> "%~dpn1%~x1".txt
ECHO %1 %date%-%time% >> "%~dpn1%~x1".txt
if not exist D:\"%~pn1--001%~x1" goto skip_delete
del /q "%1"
del /q "%~dpn1%~x1".txt
:skip_delete
as you can see, if you put(drag and drop) video files in this batch:
1. check if this file has do split before (by check if the txt exist, if exist then skip)
2. create txt file for log or check at point 1.
3. do split using PySceneDetect
4. check if the output exist, if exist then delete input files
5. (if any) do with another file and go to step 1
note: PySceneDetect is a python program, i just using the exe for convenience

i usually do this in my pc, but because the process takes a lot of time and resource(processor and ram),
i like to port it to my old android phone(android 5),
my question is :
1. is that possible?,
2. if point 1 possible and i not rude, can somebody make it for me?,
3. if im rude at point 2, can i get reference or clue, or what should i research?,
4. can python access (write and read) data/files in USB drive via OTG on android?,
5. if the drag and drop cannot be executed in android, can you make it:
all video files in "internal memory\input" and the output is in "sd card\output"?,
6. can make it 1 push button, like "for" command in windows cmd

thanks for reading,
sorry again for my bad english, and if i text to long,
have a nice day
Reply


Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020