Nano1337 commited on
Commit
22b7c4d
1 Parent(s): ace966b

Take out caption restriction for personal use

Browse files
Files changed (1) hide show
  1. processing_florence2.py +2 -3
processing_florence2.py CHANGED
@@ -263,8 +263,6 @@ class Florence2Processor(ProcessorMixin):
263
  if max_length is not None:
264
  max_length -= self.image_seq_length # max_length has to account for the image tokens
265
 
266
- text = self._construct_prompts(text)
267
-
268
  inputs = self.tokenizer(
269
  text,
270
  return_tensors=return_tensors,
@@ -1085,4 +1083,5 @@ class Florence2PostProcesser(object):
1085
  else:
1086
  raise ValueError("task {} is not supported".format(task))
1087
 
1088
- return parsed_dict
 
 
263
  if max_length is not None:
264
  max_length -= self.image_seq_length # max_length has to account for the image tokens
265
 
 
 
266
  inputs = self.tokenizer(
267
  text,
268
  return_tensors=return_tensors,
 
1083
  else:
1084
  raise ValueError("task {} is not supported".format(task))
1085
 
1086
+ return parsed_dict
1087
+