Examples: query, "exact match", wildcard*, wild?ard, wild*rd
Fuzzy search: cake~ (finds cakes, bake)
Term boost: "red velvet"^4, chocolate^2
Field grouping: tags:(+work -"fun-stuff")
Escaping: Escape characters +-&|!(){}[]^"~*?:\ with \, e.g. \+
Range search: properties.timestamp:[1587729413488 TO *] (inclusive), properties.title:{A TO Z}(excluding A and Z)
Combinations: chocolate AND vanilla, chocolate OR vanilla, (chocolate OR vanilla) NOT "vanilla pudding"
Field search: properties.title:"The Title" AND text
Answered
In Pipelines I'Ve Found That Empty Lists Don'T Work As I Would Expect Them To Work. For Example, This Will Work Fine:

In pipelines I've found that empty lists don't work as I would expect them to work. For example, this will work fine:
` from clearml.automation.controller import PipelineDecorator

@PipelineDecorator.component(cache=False)
def step_one():
my_list = [1, 2, 3, 4, 5]
return my_list

@PipelineDecorator.component(cache=False)
def step_two(some_list):
for i in some_list:
print(i)

@PipelineDecorator.pipeline(name='custom pipeline logic', project='examples', version='0.0.5')
def executing_pipeline():
my_list = step_one()
step_two(my_list)

if name == 'main':
PipelineDecorator.run_locally()
executing_pipeline() But now if I pass an empty list, like so: from clearml.automation.controller import PipelineDecorator

@PipelineDecorator.component(cache=False)
def step_one():
my_list = []
return my_list

@PipelineDecorator.component(cache=False)
def step_two(some_list):
for i in some_list:
print(i)

@PipelineDecorator.pipeline(name='custom pipeline logic', project='examples', version='0.0.5')
def executing_pipeline():
my_list = step_one()
step_two(my_list)

if name == 'main':
PipelineDecorator.run_locally()
executing_pipeline() I get this error: Traceback (most recent call last):
File "/tmp/tmpg46c1ntq.py", line 25, in <module>
results = step_two(**kwargs)
File "/tmp/tmpg46c1ntq.py", line 6, in step_two
for i in some_list:
TypeError: 'PosixPath' object is not iterable How should empty lists be handled in pipelines? Why is my empty list converted to a PosixPath ` ?

  
  
Posted one year ago
Votes Newest

Answers 7


Hi SmugSnake6
I think it was just fixed, let me check if the latest RC includes the fix

  
  
Posted one year ago

Hi SmugSnake6 . clearml==1.7.1 should support empty lists

  
  
Posted one year ago

Alright, thanks! I can confirm that it works in 1.7.1

  
  
Posted one year ago

I'm still in 1.7.0 because of the None arguments thing for now, but I'll test with the latest version if I ever find any other issue

  
  
Posted one year ago

no problem. we will soon release a RC that solves both issues

  
  
Posted one year ago

RC is out, SmugSnake6 please try with
pip install clearml==1.7.2rc1

  
  
Posted one year ago

Yep, everything works now, thanks!

  
  
Posted one year ago
962 Views
7 Answers
one year ago
one year ago
Tags