You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a lot of data to compress, and they are stored in nested subdirectories (e.g. /Data/Protein/Mutation/...pdb).
Default behavior of "foldcomp compress -r" seems to be to create an output folder, and to put everything in there. So I encounter the "Output file already exists" error.
Is there a way to either create a new directory with the same subdirectory structure? Or to output the ".fcz" files in the same directories as the uncompressed pdb files?
The text was updated successfully, but these errors were encountered:
I think you can write a script that iterate through nested sub-directories.
#!/bin/bash# Usage: ./foldcomp_recursive.sh <path> <threads>
threads=$2functionrun_command_in_dir {
fordirin"$1"/*;doif [ -d"$dir" ];then
run_command_in_dir "$dir"fidone# Check if pdb or cif files exist in the directoryif ls "$1"/*.pdb 1> /dev/null 2>&1|| ls "$1"/*.cif 1> /dev/null 2>&1;then
foldcomp compress -t $threads"$1""$1"fi
}
run_command_in_dir "$1"
This one is an example bash script that iterate through the input directory recursively and check if there are pdb or cif files in the directory while compressing if there are wanted files.
I have a lot of data to compress, and they are stored in nested subdirectories (e.g. /Data/Protein/Mutation/...pdb).
Default behavior of "foldcomp compress -r" seems to be to create an output folder, and to put everything in there. So I encounter the "Output file already exists" error.
Is there a way to either create a new directory with the same subdirectory structure? Or to output the ".fcz" files in the same directories as the uncompressed pdb files?
The text was updated successfully, but these errors were encountered: