Skip to content

Instantly share code, notes, and snippets.

@supriya-gdptl
Created February 9, 2021 22:43
Show Gist options
  • Save supriya-gdptl/3ad342ff05e4a14ae299f5057eb85c46 to your computer and use it in GitHub Desktop.
Save supriya-gdptl/3ad342ff05e4a14ae299f5057eb85c46 to your computer and use it in GitHub Desktop.
# install meshio: https://pypi.org/project/meshio/
pip install meshio
# run following in terminal to convert all .ply files from binary to ascii format INPLACE
find . -maxdepth 1 -type f -name "*.ply" -exec meshio-ascii "{}" \;
# . = current directory
# -maxdepth 1 = find files only in current directory and ignore subdirectories
# -type f = type of file to find 'regular file'
# -name "*.ply" = base of filename
# -exec [command] "{}" \; = execute command on files found. The "{}" is placeholder for filename.
# The \; is used to separate commands.
# Space between braces and semicolon is important
# Otherwise it gives error: find: missing argument to `-exec'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment