parent
ecbe4a0849
commit
1aa484200e
@ -66,6 +66,11 @@ To show all the instances estimated by MonoLoco add the argument `show_all` to t
|
||||
|
||||

|
||||
|
||||
It is also possible to run [openpifpaf](https://github.com/vita-epfl/openpifpaf) directly
|
||||
by specifying the network with the argument `--net pifpaf`. All pifpaf arguments are supported.
|
||||
|
||||

|
||||
|
||||
### Social Distancing
|
||||
To visualize social distancing compliance, simply add the argument `--social-distance` to the predict command.
|
||||
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 344 KiB After Width: | Height: | Size: 411 KiB |
BIN
docs/out_002282_pifpaf.jpg
Normal file
BIN
docs/out_002282_pifpaf.jpg
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 193 KiB |
@ -22,6 +22,7 @@ from .activity import show_social
|
||||
|
||||
LOG = logging.getLogger(__name__)
|
||||
|
||||
OPENPIFPAF_PATH = 'data/models/shufflenetv2k30-201104-224654-cocokp-d75ed641.pkl' # Default model
|
||||
|
||||
def factory_from_args(args):
|
||||
|
||||
@ -33,7 +34,12 @@ def factory_from_args(args):
|
||||
|
||||
# Model
|
||||
if not args.checkpoint:
|
||||
args.checkpoint = 'data/models/shufflenetv2k30-201104-224654-cocokp-d75ed641.pkl' # Default model
|
||||
if os.path.exists(OPENPIFPAF_PATH):
|
||||
args.checkpoint = OPENPIFPAF_PATH
|
||||
else:
|
||||
print("Checkpoint for OpenPifPaf not specified and default model not found in 'data/models'. "
|
||||
"Using a ShuffleNet backbone")
|
||||
args.checkpoint = 'shufflenetv2k30'
|
||||
|
||||
# Devices
|
||||
args.device = torch.device('cpu')
|
||||
|
||||
Loading…
Reference in New Issue
Block a user